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
Developer Community or GitHub 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.
There is an issue with MonoDevelops MSBuild host process where project configurations are not set correctly when being built. If we set the configuration as a global property, it ends up being stripped by one of the tasks in the microsoft msbuild targets files. The workaround is to set the configuration as a regular property and not a global property.
Here is the original bug report:
- Win 7 x64 (on Mac all works fine)
- MonoDevelop 220.127.116.11
- Microsoft .NET 4.0.30319.1
- Mono for Android: 4.2.5
Steps to reproduce:
- Clone https://github.com/PVoLan/TestProjRef Here is a test monodroid project, with two monodroid library projects, referenced one another.
- Make sure that all /bin and /obj folder are completely clean or deleted
- Try to build solution in Release mode
- While building Lib1.csproj you'll get an error (Pay attention that compiler tries to reference to Debug folder):
C:\Work\Test\TestProjRef\Lib1\CSC: Error CS0006: Metadata file '%PROJ_PATH%\TestProjRef\Lib2\bin\Debug\Lib2.dll' could not be found (CS0006) (Lib1)
- If you'll compile project into Debug mode, then rebuild into Release (without cleaning /bin & /obj), project will be build sucessfully, but Lib2.dll will used from previous debud build session. If you'll start application then, you'll find application output
Lib2.SomeClass.DoSmth Debug mode
Cause most of developers first use debug mode, and then build releases, this error is hard enough to detect and may be critical.
lluis, could you review this commit and let me know if it's ok? It seems to do the job just fine.
The commit listed fixes the issue for me.
Test case also added.
Commit has been reviewed and seems to be good. Closing the bug. This has already been released in MonoDevelop 18.104.22.168 aswell.