问题
I have a few apps i want to build inside my solution and I want to build them separately
running : /Applications/Xamarin\ Studio.app/Contents/MacOS/mdtool -v build "--configuration:Release|iPhone" ./42.csproj
fails.
I do see that all of Xamarin examples use a solution file (.sln) with the mdtool, but I am still wondering of there is a way to reference just on project inside my solution.
回答1:
Well After talking with xamarin they claim that using mdtool is not recommended. I was told to use xbuild and the way to do it is:
xbuild Project.sln /p:Configuration=AppStore /p:Platform=iPhone /p:BuildIpa=true /t:42
This will set the BuildIpa flag to true.
回答2:
You can run it like this:
/Applications/Xamarin\ Studio.app/Contents/MacOS/mdtool -v build -c:"Release|iPhone" -p:"42"
You need to make sure you are in your solution folder when you run this. The 42 in the above command should reference the sub folder that your iOS project file is in, not the project file itself.
来源:https://stackoverflow.com/questions/23855103/can-i-build-xamarin-ios-from-the-csproj-only-an-not-use-the-solution-command-lin