Find the answer to your Linux question:
Results 1 to 2 of 2
[root@shankar-lx src1]# make gcc -c main.c gcc -c database.c gcc -c e_sqlite.c gcc -o TEST main.o database.o e_sqlite.o /usr/local/lib/libsqlite3.so.0.8.6 -w -lpthread [root@shankar-lx src1]# ./TEST ./TEST: error while loading shared libraries: ...
  1. #1
    Just Joined!
    Join Date
    Nov 2006
    Location
    Hyderabad
    Posts
    85

    Library Linking Error

    [root@shankar-lx src1]# make
    gcc -c main.c
    gcc -c database.c
    gcc -c e_sqlite.c
    gcc -o TEST main.o database.o e_sqlite.o /usr/local/lib/libsqlite3.so.0.8.6 -w -lpthread
    [root@shankar-lx src1]# ./TEST
    ./TEST: error while loading shared libraries: /usr/lib/libsqlite3.so.0: ELF file OS ABI invalid

    My application compiled well but when try to run, it is giving ELF file OS ABI invalid ERROR.
    Can somebody tell me what is this error.

    kernel version is 2.4-18

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
    Posts
    8,974
    Is your system a 64-bit or 32-bit one? If 64-bit, then your default compiler settings is for 64-bit operations, yet you are linking to the 32-bit shared sqlite library. Rather than directly linking it, you should link it with the compiler/linker option -l sqlite3 which will pull in the correct library. Remember, in 64-bit systems, the 64-bit libraries are in /usr/lib64, not in /usr/lib.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...