[Mono-list] [OSX][WinForms] DllNotFoundException on "libgdiplus.dylib", but library installed

Eric Slosser eric.slosser at v-fx.com
Thu Jan 6 12:30:19 EST 2011


I'm not sure, but perhaps your problem is that MacPorts doesn't install xterm libraries where they're expected to be found.  I used Apple's installer.  I see the following are loaded by my WinForms app running on Snow Leopard.

/usr/X11R6/lib/libSM.6.dylib
/usr/X11R6/lib/libXrender.1.dylib
/usr/X11R6/lib/libfontconfig.1.dylib
/usr/X11R6/lib/libICE.6.dylib
/usr/X11/lib/libXau.6.dylib
/usr/X11R6/lib/libfreetype.6.dylib
/usr/X11R6/lib/libX11.6.dylib
/usr/X11/lib/libXdmcp.6.dylib


On Jan 6, 2011, at 12:12 PM, Tarnyko wrote:

> I'm trying to run my WinForms executable on Mac OS X Leopard, using official
> Mono Framework 2.8.1 . 
> 
> It crashes and I'm always getting this message : 
> An exception was thrown by the type initializer for System.Drawing.GDIPlus
> ---> System.DllNotFoundException:
> /Library/Frameworks/Mono.framework/Versions/2.8.1/lib/libgdiplus.dylibI
> turned on debug to have more details : 
> Mono: DllImport loading location:
> '/Library/Frameworks/Mono.framework/Versions/2.8.1/lib/libgdiplus.dylib' 
> Mono: DllImport error loading library: '(null)'.
> 
> I've read the FAQ, which says this file may be missing, but I'm pretty sure
> it's here : 
> # pwd 
> /Library/Frameworks/Mono.framework/Versions/2.8.1/lib 
> # ls libgdi* 
> libgdiplus.0.dylib   libgdiplus.dylib
> 
> I also thought it may be due to a missing Xorg dependency. So I downloaded
> and installed it using MacPorts : 
> # port install xorg-server
> 
> I ran the program from a xterm, but same message here... 
> I have no problems running it on Linux with Mono. 
> Can somebody help me ?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-list/attachments/20110106/9b8a7359/attachment.html 


More information about the Mono-list mailing list