link .a and .o files in GCC
- by David
hi!
I have two precompiled library: X.a and Y.a and a test.cpp (without main function) source code use these two libraries.
I compiled the C++ using:
g++ -c test.cpp
and I got 'test.o'.
Now how can I link these three together to generate a .a file because test.cpp use some function in X.a and Y.a and other GCC libraries?
BTW, I am doing…