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.
From VSFeedback 832563
Xamarin Studio 6.2 (build 1821) and VS for Mac
Mono 4.8.0 (mono-4.8.0-branch/e4a3cf3) (64-bit)
MSBuild enabled in global preferences - Projects - Build - Build with MSBuild instead of xbuild
1) Create a solution with three projects:
.NET Console project - ConsoleApp
.NET Library project - CommonLib
.NET Library project - XyzLib
2) Modify the project references so that:
ConsoleApp references CommonLib
CommonLib referencex XyzLib
3) In Common Lib modify the MyClass.cs so it uses the MyClass from the XyzLib:
public class MyClass
public MyClass ()
4) Build the solution - Build - Build All
ConsoleApp/bin/Debug folder contains CommonLib.dll and XyzLib.dll
ConsoleApp/bin/Debug folder contains just CommonLib.dll
a) If you run msbuild from the command line to build the solution then XyzLib.dll does get copied to the ConsoleApp/bin/Debug folder.
b) If you instead configure Xamarin Studio to use xbuild instead of MSBuild, close and re-open the solution, delete the files in ConsoleApp/bin/Debug, then build the solution using Xamarin Studio then XyzLib.dll does get copied to ConsoleApp/bin/Debug.
Xamarin Studio MSBuild diagnostic output:
MSBuild command line diagnostic output:
Created attachment 20288 [details]
This looks like it is an MSBuild problem. If you run MSBuild just for the console project then the XyzLib.dll is not copied to the ConsoleApp's bin/Debug folder.
msbuild /t:Build ConsoleApp/ConsoleApp.csproj
If you xbuild this works. If you run msbuild for the solution then it works. If you try building just the project with MSBuild on Windows then it works (MSBuild 14 and 15).
Created attachment 20308 [details]
MSBuild output windows - build console project
Created attachment 20309 [details]
MSBuild output - mac - build console project
This is already fixed in 4.9.x - https://github.com/mono/msbuild/commit/cff4013ba3a69f82dc0ae96b3e15af700d8f74ef .