Re: Error archiving ELF-64 relocatable object files (187 Views)
Reply
Occasional Advisor
Posts: 11
Registered: ‎08-16-2005
Message 1 of 3 (187 Views)

Error archiving ELF-64 relocatable object files

All,
This problem is related to archiving 64bit object files.
I have a static library of 64bit compiled object files. Now when I use this library to built a shared library / executable(using 64bit CC flags) linker throws following error.

ld: (Warning) Cannot load library symbol table in /project/lib/libasn.a, it might be missing or corrupted. Skipping library /project/lib/libasn.a.
1 warnings.

When I did "nm /project/lib/libasn.a" it gives following error:
nm: bits.o: File format not recognized

I guess this is common issue, most of you must have faced while trying to build 64bit executables. Do reply if you have any clue or pointers on this.
Thanks & Regards,
Dattesh Lotlikar
Honored Contributor
Posts: 1,080
Registered: ‎11-06-2003
Message 2 of 3 (187 Views)

Re: Error archiving ELF-64 relocatable object files

Hi,
You should try a
file libasn.a
mkdir /tmp/extract;cd /tmp/extract
ar x /project/lib/libasn.a
file *
I think probably bits.o will not be of the right type.
Highlighted
Esteemed Contributor
Posts: 787
Registered: ‎04-05-2005
Message 3 of 3 (187 Views)

Re: Error archiving ELF-64 relocatable object files

have you run strip or something on that library.

What were the tags you used to build library.
Either the library is corrupted or symbol table is not available.

You can check for library corruption by
file lib.a
Vibhor Kumar Agarwal
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.