-
Notifications
You must be signed in to change notification settings - Fork 554
Closed
Labels
bugIf an issue is a bug or a pull request a bug fixIf an issue is a bug or a pull request a bug fix
Milestone
Description
Repro:
-
Create a test project in a directory with a colon in it. Say ~/Projects/Colon/Test:App/
-
Build it like this:
msbuild Test:App/*.csproj /p:Platform=iPhone /r /bl /v:diag /p:ImportProjectExtensionProps=false /p:ImportProjectExtensionTargets=false
-
Fails like this:
MONO_PATH=/Users/rolf/Projects/Colon/Test:App/test-app/obj/iPhone/Debug/mtouch-cache/3-Build /Users/rolf/work/maccore/squashed-onedotnet/xamarin-macios/_ios-build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/bin/arm64-darwin-mono-sgen --debug -O=gsharedvt -O=float32 --aot=mtriple=arm64-ios,data-outfile=/Users/rolf/Projects/Colon/Test:App/test-app/obj/iPhone/Debug/mtouch-cache/arm64/System.Core.aotdata.arm64,static,asmonly,direct-icalls,full,readonly-value=ObjCRuntime.Runtime.Arch=i4/0,dwarfdebug,no-direct-calls,direct-pinvoke,outfile=/Users/rolf/Projects/Colon/Test:App/test-app/obj/iPhone/Debug/mtouch-cache/arm64/System.Core.dll.s /Users/rolf/Projects/Colon/Test:App/test-app/obj/iPhone/Debug/mtouch-cache/3-Build/System.Core.dll '/Users/rolf/Projects/Colon/Test' in MONO_PATH doesn't exist or has wrong permissions. '/Users/rolf/Projects/Colon/Test:App/test-app/App/test-app/obj/iPhone/Debug/mtouch-cache/3-Build' in MONO_PATH doesn't exist or has wrong permissions. The assembly mscorlib.dll was not found or could not be loaded. It should have been installed in the `/Users/builder/jenkins/workspace/archive-mono/2020-02/ios/release/sdks/out/ios-cross64-release/lib/mono/4.5/mscorlib.dll' directory. AOT Compilation exited with code 1, command:
The reason is that MONO_PATH can be multiple paths, separated by colon, and there doesn't seem to be a way to escape the colon.
Ideas to fix:
- Figure out a way to pass MONO_PATH with colons (runtime fix).
- Maybe it could work if we changed the current directory to the desired path and not set MONO_PATH?
Mitigation if we wish to:
- Detect colons in the desired path, and show a better error (something like "AOT compilation is not supported for directories with colons").
Other notes:
- This happens if OutputPath or IntermediateOutputPath is set to a full path on Windows.
Binlog: msbuild.binlog.zip
Metadata
Metadata
Assignees
Labels
bugIf an issue is a bug or a pull request a bug fixIf an issue is a bug or a pull request a bug fix