Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
GitHub or Developer Community with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 5959 [details]
Example project with Build Target .NET 4.0 and no references. Add System 184.108.40.206 as reference for the project to be able to build.
If System 220.127.116.11 is not in the references, xbuild builds with System 18.104.22.168 even if build target is Mono / .NET 4.0.
What version of Mono?
Can someone confirm how .NET's MSBuild behaves in this case?
Mono version 3.2.3.
A friend of mine tried latest VS and the behaviour is the same. He also noted, that new projects automatically include the System 22.214.171.124 in the references. Monodevelop does not do this.
I cannot reproduce this. When I build the attached project with xbuild, I get:
Tool /Users/michael/Mono/bockbuild/profiles/monodevelop-mac-dev/build-root/_install/bin/dmcs execution started with arguments: /noconfig /debug:full /debug+ /optimize- /out:obj/x86/Debug/BuildTargetExample.exe Program.cs obj/x86/Debug/.NETFramework,Version=v4.0.AssemblyAttribute.cs /target:exe /define:DEBUG /platform:x86 /reference:/Users/michael/Mono/bockbuild/profiles/monodevelop-mac-dev/build-root/_install/lib/mono/4.0/System.Core.dll /warn:4
It's not building with System.dll 126.96.36.199, it's building without System.dll at all. This is correct, because the project doesn't include a System.dll reference.
I'm assuming you used the "Empty Project" template? It's completely empty, no files or references. Other templates do have a System.dll reference.