Library loading problem for Linux applications

Alexander Leidinger Alexander at Leidinger.net
Fri Jun 15 05:50:29 UTC 2007


Quoting "Sean C. Farley" <sean-freebsd at farley.org> (from Thu, 14 Jun  
2007 15:40:40 -0500 (CDT)):

> Since the xorg 7.2 upgrade, I have been unable to run games/linux-ut
> (maintainer is yours truly).  I believe it to be the way the libraries
> are being loaded that is causing the problem.
>
> If I try to run the ut (shell script that runs ut-bin), I believe
> SDLDrv.so is having trouble finding the Linux libXext.so.6.
>
> ut -log output (snipped):
> Bound to SDLDrv.so
> appError called:
> Couldn't initialize SDL: No available video device
>
> ktrace output:
> 52006 ut-bin   CALL  open(0xbfbfc5c0,0,0x287078ab)

Please use linux_kdump or truss, the FreeBSD kdump doesn't translate  
Linux syscalls.

> If I fix the problem by running (cd /compat/linux/usr && ln -s X11R6
> local), then this is solved.  Of course, there has to be a second
> problem; it cannot find the Linux libGL.so.1.
>
> ut -log output (snipped):
> Bound to OpenGLDrv.so
> Loaded render device class.
> Initializing OpenGLDrv...
> binding libGL.so.1
> appError called:
> Failed loading libGL.so.1: /usr/local/lib/libGL.so.1: ELF file OS ABI invalid
>
> ktrace output:
> 1395 ut-bin   CALL  open(0xbfbfc870,0,0)
> 1395 ut-bin   NAMI  "./tls/libGL.so.1"
> 1395 ut-bin   RET   open JUSTRETURN
> 1395 ut-bin   CALL  open(0xbfbfc870,0,0)
> 1395 ut-bin   NAMI  "./libGL.so.1"
> 1395 ut-bin   RET   open JUSTRETURN
> 1395 ut-bin   CALL  open(0xbfbfc870,0,0)
> 1395 ut-bin   NAMI  "/compat/linux/usr/local/lib/tls/libGL.so.1"
> 1395 ut-bin   NAMI  "/usr/local/lib/tls/libGL.so.1"
> 1395 ut-bin   RET   open JUSTRETURN
> 1395 ut-bin   CALL  open(0xbfbfc870,0,0)
> 1395 ut-bin   NAMI  "/compat/linux/usr/local/lib/libGL.so.1"
> 1395 ut-bin   NAMI  "/usr/local/lib/libGL.so.1"
> 1395 ut-bin   RET   open 49/0x31
>
> What is the correct solution to have the Linux application search all
> relevant directories in /compat first?  LD_LIBRARY_PATH is ignored by

That's the default.

> these open() calls.  The nVidia libGL.so.1 is installed in
> /compat/linux/usr/lib.

Do you have the right ld.so.conf (LINUXBASE/etc/) and  
ld.so.conf.d/xorg-x11-i386.conf? The linux ldconfig has to be run  
(chrooted). To be on the safe side remove all linux ports, clean  
/compat/linux, and resinstall the linux ports. Currently it sounds  
like a ldconfig problem...

Bye,
Alexander.

-- 
If sarcasm were posted on Usenet, would anybody notice?
		-- James Nicoll

http://www.Leidinger.net    Alexander @ Leidinger.net: PGP ID = B0063FE7
http://www.FreeBSD.org       netchild @ FreeBSD.org  : PGP ID = 72077137


More information about the freebsd-emulation mailing list