This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
RE: why is g++ relocation error linking only showing when listing objects explicitly?
OK. Thank you Jonathan very much. This was exactly right, xargs command line length limitation, the follow-up question not-on-topic. Sorry.
But now after learning from that, I am still having the 24-bit error relocation problem, when linking 2300 .o files into a lib, total size 29MB.
I guess it has something to do with 29MB being over 2^24 bytes?
Jonathan says to add them one by one to an "archive".
I am really sorry for the naÃve question, but I did RTFM, and I cannot find anything about "archiving".
What I am doing right now is
>g++ --shared -fPIC -Wl,-soname,<.so file> "<command to list object files"
Does not work due to 24-bit relocation problem.
How do I replace it with "adding one by one to an archive"?? I am sorry, but I RTFMd and I don't find anything about that.
Mark