This is Xamarin's bug tracking system. For product support, please use the support links listed in your Xamarin Account.
Bug 2727 - Wrapper script removes DYLD_FALLBACK_LIBRARY_PATH default
Summary: Wrapper script removes DYLD_FALLBACK_LIBRARY_PATH default
Status: RESOLVED FIXED
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Mac Add-in (show other bugs)
Version: 2.8.4.1
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: Miguel de Icaza
URL:
Depends on:
Blocks:
 
Reported: 2012-01-03 17:06 UTC by Jean-Louis Fuchs
Modified: 2012-02-07 09:05 UTC (History)
2 users (show)

See Also:
Tags:


Attachments

Description Jean-Louis Fuchs 2012-01-03 17:06:20 UTC
Version: MonoDevelop 2.8.5 (not selectable)

Symptom: System libraries not found (System.DllNotFoundException: libc.dylib) when a mono created .app is started outside of MonoDevelop.

In the wrapper-script created by mono develop: MyApp.app/Contents/MacOS/MyApp DYLD_FALLBACK_LIBRARY_PATH is set without including default. Since an empty  DYLD_FALLBACK_LIBRARY_PATH means the default this will remove default. System libraries cannot be found.

Please see: http://developer.apple.com/library/mac/#documentation/Darwin/Reference/Manpages/man1/dyld.1.html

In my opition the line should be:

	export DYLD_FALLBACK_LIBRARY_PATH="$MONO_FRAMEWORK_PATH/lib:$DYLD_FALLBACK_LIBRARY_PATH:$(HOME)/lib:/usr/local/lib:/lib:/usr/lib"

Or a check if DYLD_FALLBACK_LIBRARY_PATH is empty would be even better.
Comment 1 Miguel de Icaza 2012-01-03 19:43:19 UTC
Good observation Jean-Louis.

The fix has been added.
Comment 2 Rolf Bjarne Kvinge 2012-02-07 06:16:03 UTC
The wrapper-script now says:

line 20: HOME: command not found

shouldn't it be ${HOME} instead of $(HOME)?
Comment 3 Jean-Louis Fuchs 2012-02-07 07:36:17 UTC
Yes. That way the ~/lib doesn't work. It's on line 20 and line 51.

(Hmm, it is wrong in man dyld)
Comment 4 Rolf Bjarne Kvinge 2012-02-07 09:05:00 UTC
Thanks, fixed.

Note You need to log in before you can comment on or make changes to this bug.