Subject: Re: COMPAT_LINUX: matching LinuxPPC binaries
To: Emmanuel Dreyfus <p99dreyf@criens.u-psud.fr>
From: Todd Vierling <tv@wasabisystems.com>
List: tech-kern
Date: 01/02/2001 19:09:37
On Wed, 3 Jan 2001, Emmanuel Dreyfus wrote:

: in the .stabstr section of my hello world programm, I can find some
: strings: "config/rs6000/linux", "config/xm-linux", but it seems we can't
: rely on them: I can't find them in the awk command, for instance.

Stripped binaries won't have stabs sections.

: I wrote a piece of code to test the existence of the __libc_atexit
: section, and it works. I use it to match statically linked binaries.

This might be your only bet, then.  A section named __libc_atexit sounds
awfully strange to be on any system except linux, so I personally would
favor this.

-- 
-- Todd Vierling <tv@wasabisystems.com>  *  Wasabi NetBSD:  Run with it.
-- NetBSD 1.5 now available on CD-ROM  --  http://www.wasabisystems.com/