invalid ELF header in libc.so (Ubuntu)

Started by kanen, March 25, 2010, 11:32:24 AM

Previous topic - Next topic

kanen

When I attempt to import the unix.lsp module, I get an "invalid ELF header" error.



The results are below.



I have tried the Ubuntu apt-get version and the version compiled from source. Both have the same problem.



Any ideas? Am I missing something obvious?


kanen@openkane:~/Source/newlisp-10.2.1$ ./newlisp
newLISP v.10.2.1 on Linux IPv4 UTF-8, execute 'newlisp -h' for more info.

> (load "unix.lsp")

ERR: problem loading library in function import : "/usr/lib/libc.so: invalid ELF header"
> kanen@openkane:~/Source/newlisp-10.2.1$ head /usr/lib/libc.so
/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf32-i386)
GROUP ( /lib/libc.so.6 /usr/lib/libc_nonshared.a  AS_NEEDED ( /lib/ld-linux.so.2 ) )
. Kanen Flowers http://kanen.me[/url] .

kanen

#1
Modified the unix.lsp code:


     "/usr/lib/libpcap.so.1.0.0"; UBUNTU 9.04
     ;"/usr/lib/libc.so" ; Linux, BSD, Solaris


Problem solved.
Quote from: "kanen"When I attempt to import the unix.lsp module, I get an "invalid ELF header" error.



The results are below.



I have tried the Ubuntu apt-get version and the version compiled from source. Both have the same problem.



Any ideas? Am I missing something obvious?


kanen@openkane:~/Source/newlisp-10.2.1$ ./newlisp
newLISP v.10.2.1 on Linux IPv4 UTF-8, execute 'newlisp -h' for more info.

> (load "unix.lsp")

ERR: problem loading library in function import : "/usr/lib/libc.so: invalid ELF header"
> kanen@openkane:~/Source/newlisp-10.2.1$ head /usr/lib/libc.so
/* GNU ld script
   Use the shared library, but some functions are only in
   the static library, so try that secondarily.  */
OUTPUT_FORMAT(elf32-i386)
GROUP ( /lib/libc.so.6 /usr/lib/libc_nonshared.a  AS_NEEDED ( /lib/ld-linux.so.2 ) )
. Kanen Flowers http://kanen.me[/url] .

Lutz

#2
To import libc.so on UBUNTU 9.04 linux try "/lib/libc.so.6" instead. The online module has been updated with this.