cannot find -lstdc++

A

Adam

Hi

I have been trying to compile a program and keep getting this error

gcc -g -Wall -c filecopy.c
g++ -static -g -o assess mark.o mark1.o mark2.o mark3.o mark4.o
mark5.o mark5a.o mark5b.o mark5c.o mark5d.o mark6.o markio.o mark7.o
markutil.o markclas.o rportptr.o strupr.o scrnpagr.o scrnform.o
markver.o markform.o date.o filecopy.o -lncurses
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make: *** [assess] Error 1
[lgm@buzz src]$

any help would be great.

Thanks Adam
 
B

Buster

Adam said:
I have been trying to compile a program and keep getting this error

gcc -g -Wall -c filecopy.c
g++ -static -g -o assess mark.o mark1.o mark2.o mark3.o mark4.o
mark5.o mark5a.o mark5b.o mark5c.o mark5d.o mark6.o markio.o mark7.o
markutil.o markclas.o rportptr.o strupr.o scrnpagr.o scrnform.o
markver.o markform.o date.o filecopy.o -lncurses
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make: *** [assess] Error 1
[lgm@buzz src]$

any help would be great.

On my system, libstdc++.a is right there in /usr/lib/. Maybe your
installation is faulty. This newsgroup discusses the C++ language.
It's not the most suitable place for your question. See the FAQ
and welcome message.
 
J

Jorge Rivera

Adam said:
Hi

I have been trying to compile a program and keep getting this error

gcc -g -Wall -c filecopy.c
g++ -static -g -o assess mark.o mark1.o mark2.o mark3.o mark4.o
mark5.o mark5a.o mark5b.o mark5c.o mark5d.o mark6.o markio.o mark7.o
markutil.o markclas.o rportptr.o strupr.o scrnpagr.o scrnform.o
markver.o markform.o date.o filecopy.o -lncurses
/usr/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make: *** [assess] Error 1
[lgm@buzz src]$


You shouldn't need to. The problem I see is that you are compiling with
gcc and linking with g++. Try being consistent (if using c++, use g++,
C, gcc)

JLR
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,164
Messages
2,570,898
Members
47,439
Latest member
shasuze

Latest Threads

Top