LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 02-08-2006, 12:38 PM   #1
ofanan
LQ Newbie
 
Registered: Feb 2006
Posts: 2

Rep: Reputation: 0
linker error: ld: cannot find -lstdc++


When trying to link as follows:
g++ -static -O3 -I -I/home/ofanan/gmp-4.1.4 -I. -DGMP -L/usr/lib -L/home/ofanan/gmp-4.1.4 cdd_r.o cddrevs_r.o cddio_r.o cddarith_r.o cddpivot_r.o setoper.o gmp_init.o Integer.o Rational.o -o cddr+ -lstdc++ -lgmp

I get the error:
/usr/bin/ld: cannot find -lstdc++
though I indeed have the following libraries under /usr/lib:
libstdc++.so.5@
libstdc++.so.5.0.5*
libstdc++.so.6@
libstdc++.so.6.0.3*
And I set within the Makefile:
LIBDIR = /usr/lib
I have also /usr/lib found in PATH and LIB variables (is it necessary, BTW?)
Actually, I found a few more libstdc++ libraries in other directories, which also should be recognized (I think) by g++.
I use gcc version 3.3.2 (Mandrake Linux 10.0 3.3.2-6mdk)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ld linker error Ankit mittal Programming 2 09-30-2005 07:40 AM
qt compile cannot find lstdc++ poboy975 Linux - Software 3 01-08-2005 01:03 PM
g++ error lstdc++ develinux Programming 3 04-22-2004 12:50 PM
Linker Error dim79 Programming 2 06-28-2003 09:53 AM
Installing Iperf >>cannot find -lstdc++!!!! RKris Linux - Software 1 12-16-2002 12:26 PM


All times are GMT -5. The time now is 02:04 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration