Command-line to combine obj files (.o) into a Static Library (lib.a) file.
807578Aug 3 2009 — edited Aug 5 2009I have a library that I need to compile for Solaris 10 x86 using Sun Studio. I compile the source files to make obj files by issuing the command:
Bash-3.0# cc -c -D"_UNIX_" *.c
This compiles every source.c and produces an object.o file. (Nice, & simple.)
Now, what is the command-line to combine all those object.o files (along with a few other staticlibs.a) and make one archive, lib.a?
I've done this many times with the gnu - gcc compilers. Is it possible with the Sun Studio Tools? And where is it documented?
I thought I had this 'licked' when installed SS12u1 and built the 'Welcome' project. But I have searched the "Sun Studio 12: C User's Guide" from top to bottom, and I don't have a 'clue' :-( ...
Mike <><><>