Re: Problems finding libraries during linking

From: Kai Ruottu <karuottu_at_freenet.hut.fi>
Date: Fri, 22 Dec 2000 10:11:26 GMT
Message-ID: <3a431f90.5184494_at_news.yhteys.mtv3.fi>


On Thu, 21 Dec 2000 22:37:17 -0800, Daniel <dlrubinANTI-SPAM_at_yahoo.com> wrote:

>I'm trying to statically link libraries associated with an application
>using Oracle PRO*C, but get the following errors related to being unable
>to find some of the libraries. I have LD_LIBRARY_PATH set to the Oracle
>lib directory. Here's my link line and the errors:
>
>/usr/local/bin/g++ -o SubmitData SubmitData.o
>-L/usr/pubsw/apps/oracle/8.1.6/lib/ -lclntsh `cat
>/usr/pubsw/apps/oracle/8.1.6/lib/sysliblist` -R
>/usr/pubsw/apps/oracle/8.1.6/lib -laio -lm -lthread -static
>-R/usr/pubsw/apps/oracle/8.1.6/lib ../yacgi12/
>lib/libyacgi.a -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.6/2.95.2/
>-lstdc++
>ld: fatal: library -lclntsh: not found
>ld: fatal: library -ldl: not found
>ld: fatal: library -lsched: not found
>ld: fatal: library -laio: not found
>ld: fatal: library -lthread: not found
>ld: fatal: File processing errors. No output written to SubmitData
>collect2: ld returned 1 exit status
>make[1]: *** [cppbuild] Error 1
>
>
>Any ideas?

 Please try the 'verbose' option for the linker, like:

/usr/local/bin/g++ -Wl,-verbose -o SubmitData SubmitData.o \ -L/usr/pubsw/apps/oracle/8.1.6/lib/ -lclntsh \ ....

 Then you will see where it tries to find the libs.

Cheers, Kai Received on Fri Dec 22 2000 - 11:11:26 CET

Original text of this message