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.
MonoDevelop doesn't show all the assemblies that are present in GAC when editing project references. The assemblies I tried to add references to are I18N.dll and I18N.West.dll both of which are both in GAC and in $PREFIX/lib/mono/X.Y/ where X.Y is a profile version.
In order to reference such assemblies one has to use direct assembly file reference, which is suboptimal as those assemblies are part of Mono distribution and one cannot count on their location not to change.
MonoDevelop should show all the "public" assemblies present in the profile directories when editing project references.
GAC is for runtime, not compile time.
See http://monodevelop.com/FAQ#I_added_an_assembly_to_the_GAC.2c_why_doesn't_it_appear_in_the_assemblies_list_when_I_try_to_add_a_reference_in_a_MonoDevelop_project.3f and http://msdn.microsoft.com/en-us/library/wkze6zky(v=VS.100).aspx
Why are you trying to add references to those assemblies? They're not part of any framework profile, they're Mono internal implementation details, you should should never need to reference them directly.
Indeed, GAC is for the runtime but the assemblies in question are also in $prefix/lib/$profile/ and that's a compile time location.
I'm adding the assemblies as reference because I need them in my MonoMac bundle and this is the only way to force mmp to put them there. They are necessary for Ionic.Zip to work. Those assemblies are loaded dynamically by System.Text.Encoding.GetEncoding, so there's no easy way for mmp to know that they are needed. It should probably include them unconditionally for that reason, IMO.
That's an mmp bug, we shouldn't be exposing private assemblies to the reference system to work around it. They may be in the framewokr directory but they're not actualy part of the framework profile.
The real fix is for mmp & MonoDevelop.MonoMac to handle the encoding assemblies the same way that MonoTouch does.
If the assembly is in $prefix/lib/$profile then it is not private, and MD should allow linking against it. If the i18n assemblies are to be private, they should be removed from the profile and just left in GAC.
Sebastien, could you implement in mmp whatever MonoTouch does in this situation?
No I can't, it would be a waste of time...
Seriously mmp already support this using the -i18n option (just like MonoTouch linker does).
--i18n=VALUE List of i18n assemblies to copy to the output
directory, separated by commas (none,all,cjk,
However the MonoMac addin inside MD does not have a similar GUI (like the iPhone Addin has) to let user set the I18N options or even give a way to let the users provide extra arguments to the linker.
I see, thanks Sebastien!
*** This bug has been marked as a duplicate of bug 1650 ***