How to use older libs in 32bit mode?
Peter Wemm
peter at wemm.org
Thu Nov 25 12:42:35 PST 2004
On Wednesday 24 November 2004 07:10 pm, Jean-Yves Avenard wrote:
> On 24/11/2004, at 6:06 PM, Michael R. Wayne wrote:
> > Sorry. No success as in it cores.
>
> Exact same thing here. Any attempts to run a 32 bits executable on an
> AMD64 machines result in a coredump
>
> Jean-Yves
Things to check:
* Make sure you have COMPAT_IA32 in your kernel config. For example,
this command should work:
peter at overcee[8:16pm]~/fbp4/hammer/sys/amd64/conf-120> sysctl kern.elf32
kern.elf32.fallback_brand: -1
(The important thing is that it prints something, not the value)
* Make sure you have NOT copied ld-elf or libc from an i386 system.
You *MUST* build at least these two on your machine. How to check:
peter at overcee[8:17pm]~-123> strings /libexec/ld-elf32.so.1 | grep libmap32
/etc/libmap32.conf
If this comes up empty, you're in trouble. Check that
/usr/libexec/ld-elf32.so.1 and /libexec/ld-elf.so.1 are the same file.
If you are running 5.3-stable and not 5.3-release, you can check libc
like this:
peter at overcee[8:18pm]~-125> objdump --dynamic-syms /usr/lib32/libc.so.5 | grep fsbase
00026500 g DF .text 0000002b _amd64_set_fsbase
00026580 g DF .text 0000004a _amd64_get_fsbase
These will not be present on a 5.3-release system.
Oh wait a second. Did you build your libraries with
WITH_LIB32=yes or by running build32.sh ? I have a suspicion
that build32.sh will produce a bad library now.
BTW: it is helpful to do a ktrace/kdump and show the last few lines.
I suspect there will be a sysarch syscall, followed by a SIGSEGV.
--
Peter Wemm - peter at wemm.org; peter at FreeBSD.org; peter at yahoo-inc.com
"All of this is for nothing if we don't go to the stars" - JMS/B5
More information about the freebsd-amd64
mailing list