This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: problem creating a static library
On Sep 30, 2004, at 1:39 PM, Danilo José wrote:
I suppose that .s file is the .a file
.s is the assembly version of the file. See man gcc under -save-temps.
The thing is that I need to use the .a file, because it is a
requirement
of the migration to Mac Os X.
Ok, another solution would be ld -r *.o -o new.o and put new.o in the
.a file. This might be the easiest to get working for you, now that I
think of it.
2) I think the problems come because StdError.o does has undefined
that
method. Because if I include in the code of the StdError.c the template
instantiation that is not found, it does not have any problem to
compile.
But I can not do this because I can not duplicate the code, because
that
file is already compiled in another object.
I don't know what you mean by cannot duplicate code. template
instantiation doesn't duplicate code[1].
What is the other way that you told me of doing a workaround, I
did not
understand it very well.
Remove the string notoc (or no_toc) and the extra , from the .s files
before assembling.
1 - size a.out numbers remain the same, the summation of all the .o
files appears larger than the a.out numbers.