problem with executables

Ken Moffat ken at linuxfromscratch.org
Sat Nov 26 10:41:41 PST 2005


On Sat, 26 Nov 2005, jstipins at umich.edu wrote:

>
> I am running a pure64 x86_64 linux with kernel 2.6.14.2.  Here is the output
> of the "file" command:
>
> jstipins at lokiman:~$ file /bin/ls
> /bin/ls: ELF 64-bit LSB executable, AMD x86-64, version 1 (SYSV), for 
> GNU/Linux 2.6.0, dynamically linked (uses shared libs), for GNU/Linux 2.6.0, 
> not stripped
>
>
> When I download a binary for x86-64, such as the following computer algebra
> package, I get this:
>
> jstipins at lokiman:~$ file /usr/local/cocoa-4.5/cocoa_qt
> /usr/local/cocoa-4.5/cocoa_qt: ELF 64-bit LSB executable, AMD x86-64, version 
> 1 (SYSV), for GNU/Linux 2.4.1, dynamically linked (uses shared libs), for 
> GNU/Linux 2.4.1, stripped
>
> So it's been compiled for a different kernel.

  Not quite - it's been compiled for the linux-2.4 kernel interfaces in 
glibc, which we override with --enable-kernel=.  I guess things like 
linuxthreads might be involved too.

>  When I try to execute it, this
> happens:
>
> jstipins at lokiman:~$ /usr/local/cocoa-4.5/cocoa_qt
> -sh: /usr/local/cocoa-4.5/cocoa_qt: No such file or directory
>
> jstipins at lokiman:~$ ldd /usr/local/cocoa-4.5/cocoa_qt
> /usr/bin/ldd: line 116: /usr/local/cocoa-4.5/cocoa_qt: No such file or 
> directory
>
> And this seems to happen for any binary which was compiled on a 2.4 kernel,
> not just this one.
>
> What exactly is happening here?
>

  I've no real idea. First, does ldd work on normal binaries you've 
compiled (at various times I've seen ldd scripts with multilib library 
references in them on pure64 - I thought that was resolved, but it 
causes no end of confusion if it isn't.) ?

  Second, does strace show anything interesting ? (4.5.12 needs a patch 
for our recent glibc).

  There was something rather similar on blfs-support in the last couple 
of months, where a binary package on x86 seemed to show this sort of 
behaviour, but I can't seem to find it.

  However, since this is a precompiled package, and no distros other than 
than debian amd64 are using pure64, I guess it's intended for lib64.

Ken
-- 
  das eine Mal als Tragödie, das andere Mal als Farce


More information about the cross-lfs mailing list