Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Apr 2008 17:46:11 +0200
From:      Tijl Coosemans <tijl@ulyssis.org>
To:        freebsd-emulation@freebsd.org
Subject:   Re: googleearth & skype trouble
Message-ID:  <200804191746.12611.tijl@ulyssis.org>
In-Reply-To: <40533363@bb.ipt.ru>
References:  <480921B2.6030004@inode.at> <40533363@bb.ipt.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On Saturday 19 April 2008 17:03:56 Boris Samorodov wrote:
> On Sat, 19 Apr 2008 00:33:22 +0200 Armin Pirkovitsch wrote:
>> When I try to start them I get:
>> <program>: error while loading shared libraries:
>> /usr/lib/librt.so.1: ELF file OS ABI invalid
> 
> From your kdump:
> -----
>  98302 googleearth-bin NAMI  "/compat/linux/lib/librt.so.1"
>  98302 googleearth-bin NAMI  "/compat/linux"
>  98302 googleearth-bin NAMI  "/compat/linux/lib/librt.so.1"
>  98302 googleearth-bin RET   linux_open 3
>  98302 googleearth-bin CALL  read(0x3,0xbfbfd92c,0x200)
>  98302 googleearth-bin GIO   fd 3 read 512 bytes
> [...]
>  98302 googleearth-bin RET   read 512/0x200
>  98302 googleearth-bin CALL  close(0x3)
>  98302 googleearth-bin RET   close 0
>  98302 googleearth-bin CALL  linux_open(0xbfbfd800,0,0x4805d5ab)
>  98302 googleearth-bin NAMI  "/compat/linux/usr/lib/tls/librt.so.1"
>  98302 googleearth-bin NAMI  "/usr/lib/tls/librt.so.1"
>  98302 googleearth-bin RET   linux_open JUSTRETURN
>  98302 googleearth-bin CALL  linux_open(0xbfbfd800,0,0x4805d5ab)
>  98302 googleearth-bin NAMI  "/compat/linux/usr/lib/librt.so.1"
>  98302 googleearth-bin NAMI  "/usr/lib/librt.so.1"
>  98302 googleearth-bin RET   linux_open 3
>  98302 googleearth-bin CALL  read(0x3,0xbfbfd92c,0x200)
>  98302 googleearth-bin GIO   fd 3 read 512 bytes
> [...]
> -----
> 
> The linux library is found but not used. And then the native FreeBSD
> one is got tried, hence the error occures. Sorry, but that seems to
> be a symptom of linux.osrelease=2.6.16 requirement for those
> applications to run.

Actually, this is a known problem with linux_base-fc4 and 2.4.2
emulation. It pops up on the mailinglists now and then so it's starting
to become a faq.

One of the solutions is to create a softlink:

ln -f ../../lib/librt.so.1 /compat/linux/usr/lib/librt.so.1

That way, the linux compat open(2) syscall never returns the FreeBSD
librt.so.1 and the linker eventually finds the 2.4.2 compatible version
/compat/linux/lib/obsolete/linuxthreads/librt.so.1.

Somebody should at this to a post-install target in the port/package,
because /compat/linux/bin/ls and some others are affected as well.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200804191746.12611.tijl>