archiving c libraries
Daniel Montagnese
plug-devel@lists.PLUG.phoenix.az.us
Mon Apr 23 09:01:02 2001
--0-218751296-988136870=:27988
Content-Type: text/plain; charset=us-ascii
How are c libraries archived?
An attempt yielded the following results:
Two c source code files were compiled using:
gcc -shared -o libxxx.a source.c
The files that were output were archived using:
ar rus libcombined.so list-of-the-two-files
Another c source code file with a main function was compiled using:
gcc -o product -L. main.c -lcombined
The "product" executable was successfully output, but when it was run, the following error message was shown:
product: error in loading shared libraries: libxxx.a: cannot open shared object file
Glad you are there,
Dan Montagnese
---------------------------------
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
--0-218751296-988136870=:27988
Content-Type: text/html; charset=us-ascii
<P>How are c libraries archived?</P>
<P>An attempt yielded the following results:</P>
<P>Two c source code files were compiled using:<BR> gcc -shared -o libxxx.a source.c</P>
<P>The files that were output were archived using:<BR> ar rus libcombined.so list-of-the-two-files</P>
<P>Another c source code file with a main function was compiled using:<BR> gcc -o product -L. main.c -lcombined</P>
<P>The "product" executable was successfully output, but when it was run, the following error message was shown:<BR> product: error in loading shared libraries: libxxx.a: cannot open shared object file</P>
<P> </P>
<P>Glad you are there,</P>
<P>Dan Montagnese</P><p><br><hr size=1><b>Do You Yahoo!?</b><br>
<a href="http://auctions.yahoo.com/">Yahoo! Auctions</a> - buy the things you want at great prices
--0-218751296-988136870=:27988--