freebsd32 organization?
Peter Wemm
peter at wemm.org
Fri Mar 19 17:57:26 PST 2004
On Thursday 18 March 2004 01:07 pm, Andrew Gallatin wrote:
> What's the "standard" way of installing 32-bit freebsd libraries
> so as to be able to run a 32-bit binary?
>
> What I did was to copy ld-elf.so.1 from a 4.9 machine to
> /libexec/ld-elf-32.so.1, and then copy the 4.9 libs
> to a lib32 directory, and then launch 32-bit binaries
> with a wrapper script that sets LD_LIBRARY_PATH to lib32.
>
> This is a total hack, and I assume there must be a better way.
The are better ways, the best is probably to grab the ld-elf-32.so.1
from http://people.freebsd.org/~peter/ld-elf-32.so.1
I do have a slightly more refined system in the p4 tree, but it is still
an evil hack. I think I've figured out how to get the tree impact down
to an acceptable level.
I've split out the 32 bit libraries part of my current WIP. You can see
it here: http://people.freebsd.org/~peter/lib32.diff
Note that there is one small kernel diff there. You use this by doing a
buildworld/installworld, and after that is finished, run the build32.sh
script. That sets up a temporary include tree, builds 32 bit libraries,
installs them, and builds a ld-elf32.so.1. You can set paths for it via
the "-32" flag to ldconfig.
> FWIW, I'm doing this because firefox (built from ports cvsupped
> today) exits randomly, so I'm running mozilla built on a 4.9 box..
This is a libpthread problem, for reasons I haven't been able to track
down yet. The best cheat method is to use libmap to translate all
the libpthread.so.1 references to libc_r.so.5. It turns out to be quite
robust with libc_r. The libpthread problem appears to be the good old
misaligned stack problem lurking somewhere.
I'll be tackling this next. I do recommend using the 64 bit firefox
though, it is rock solid with libc_r.
--
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