Problem running X11 on PPC Mac

Deborah Goldsmith dgoldsmith at mac.com
Wed Nov 15 10:37:17 EST 2006


On Nov 15, 2006, at 6:14 AM, Christian Maeder wrote:
> Gregory Wright schrieb:
>>> /opt/local/lib/ghc-6.6/HSX11_cbits.o: unknown symbol `_printf 
>>> $LDBLStub'
>>
>> I think I remember seeing something like this.  I'll look into it  
>> some
>> more.
>
> That's a gcc problem. I think, HSX11_cbits.o should be built with
> gcc-3.3. (I assume your default is gcc-4.0.)
>
> Try adding "-pgmc /usr/bin/gcc-3.3" to ghc's command-line.
>
> Christian
>
> P.S. I had to set DYLIB_LIBRARY_PATH, before it worked for me

Actually, I've been able to build GHC from source using gcc 4.0.1  
with no problems or special DYLIB_LIBRARY_PATH. I've also had no  
problems running X11 programs (from xterm) via either ghc or ghci.  
I'm not sure what's going on here. If you are still getting the  
unknown symbol you can fix it by adding -lSystemStubs to the link.  
That should happen automatically if everything is building properly.

I think this may be a problem with the way the macports port is set  
up. Maybe try building it by hand, or using the binary distribution?  
(Although the Intel binary distribution is broken for X11, the PPC  
one works).

Gregory, one thing to check: if X11 was installed properly, there  
should be a symbolic link /usr/lib/X11 -> /usr/X11R6/lib/X11. If it's  
not there, then do:

sudo ln -s /usr/lib/X11 /usr/X11R6/lib/X11

Also, are you running 10.3 (Panther) or 10.4 (Tiger)?

Deborah



More information about the Glasgow-haskell-users mailing list