On Mon, Feb 12, 2007 at 06:04:36PM +0100, Karel Kulhavy wrote:
>  16287 yes      CALL  #243 (unimplemented linux_sys_set_thread_area)()
>  16287 yes      PSIG  SIGSYS SIG_DFL code 0
>  16287 yes      NAMI  "yes.core"
> 
> What does this mean? That linux_sys_set_thread_area is unimplemented in the 
> emulation?
>

IIRC, it's like that:

The linux ld-linux.so dynamic linker calls uname(), gets the version
of the kernel (4.0 on OpenBSD), and based on the fact that 4.0 > 2.5.58
(or something similar) decides that you're running a 2.6.X NPTL-able
kernel, and goes on to set up things for NTPL threads with
set_thread_area(), etc, even if the program is a non-threaded one.

The solution to that is to run the linux binary with

LD_ASSUME_KERNEL=2.4.2

in the environment.

(in FreeBSD, they have added a sysctl to fake a linux kernel version;
 that is completely unnecessary).

However, fixing that won't get you too far -- there are other
problems (first, the simplest one, are the PROT_GROWS{UP,DOWN}
flags to linux' mmap()).

And, finally, the 'shadow root' idiocy is completely unusable, mainly
because of symlinks and binaries that call linux-only shell scripts.

Reply via email to