Porting linux-wine
Alexander Leidinger
Alexander at Leidinger.net
Fri Oct 28 06:49:06 PDT 2005
Ulrich Spoerlein <q at galgenberg.net> wrote:
> On Fri, 28.10.2005 at 08:51:30 +0200, Alexander Leidinger wrote:
>> Please try:
>> find /compat/linux/ -type f -print0 | xargs -0 file \
>> | grep ELF | cut -d : -f 1 | xargs brandelf -t Linux
>
> I first tried something slightly different ... and I'm shocked:
> % find /compat/linux/ -type f -print0 | xargs -0 file | grep ELF |
> cut -d : -f 1 | xargs brandelf > elf_list
> % grep -c Linux elf_list; grep -c SVR4 elf_list
> 343
> 393
>
> So there are more binaries that are not branded than binaries that are
> branded.
Welcome to one of the bugs in the linux part of the ports collection...
> After branding all bins/libs, I'm now unable to run
> /compat/linux/bin/bash because of libtermcap
[error]
You said you branded *all* libs, but libtermcap is still unbranded... is
there anything obvious which I overlooked?
[libtermcap]
> It was one of the non-branded libs. So, is branding everything
> considered bad practice?
In an ideal Ports Collection, every ELF object which is supposed to be a
linux object, is branded as such.
A static linux binary has to be branded, else you will shoot yourself in the
foot (it may cause the system to reboot or do other things you don't want to
happen). A shared linux ELF object may work as intended, but if you want to
do it properly, you have to brand them. I vote for doing it properly.
The "find ... brandelf" line is from the linux_base-8 port, althought I only
brand files in /{,usr/}{,s}bin there... obviously it needs to be extended
(not only in the linux_base-8 port). Patches are welcome.
Bye,
Alexander.
--
http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7
http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137
Robot, n:
University administrator.
More information about the freebsd-emulation
mailing list