* Re: Changing Default Linking options...
@ 1999-06-12 22:39 N8TM
1999-06-30 15:43 ` N8TM
0 siblings, 1 reply; 30+ messages in thread
From: N8TM @ 1999-06-12 22:39 UTC (permalink / raw)
To: srm765, egcs
In a message dated 99-06-12 18:54:46 EDT, srm765@merle.acns.nwu.edu writes:
<< I recently upgraded my egcs when I installed redhat 6.0 and ever since
then, libstdc++ is not being linked into my c++ programs. >>
A problem which I am seeing on some installations is that libstdc++ is
installed as a broken link. Replacing the link to libstdc++.a in the
installation directory $prefix/lib/gcc-lib/$target/egcs-2.95/ with the actual
file will fix this.
Tim
tprince@computer.org
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 22:39 Changing Default Linking options N8TM
@ 1999-06-30 15:43 ` N8TM
0 siblings, 0 replies; 30+ messages in thread
From: N8TM @ 1999-06-30 15:43 UTC (permalink / raw)
To: srm765, egcs
In a message dated 99-06-12 18:54:46 EDT, srm765@merle.acns.nwu.edu writes:
<< I recently upgraded my egcs when I installed redhat 6.0 and ever since
then, libstdc++ is not being linked into my c++ programs. >>
A problem which I am seeing on some installations is that libstdc++ is
installed as a broken link. Replacing the link to libstdc++.a in the
installation directory $prefix/lib/gcc-lib/$target/egcs-2.95/ with the actual
file will fix this.
Tim
tprince@computer.org
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:58 ` Alexandre Oliva
1999-06-12 16:04 ` Sean R Melody
1999-06-12 16:11 ` Sean R Melody
@ 1999-06-30 15:43 ` Alexandre Oliva
2 siblings, 0 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>> I recently upgraded my egcs when I installed redhat 6.0 and ever since
>> then, libstdc++ is not being linked into my c++ programs.
> egcs doesn't link with libstdc++, only eg++ does.
^ I mean `g++' here
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 23:15 ` Jeffrey A Law
@ 1999-06-30 15:43 ` Jeffrey A Law
0 siblings, 0 replies; 30+ messages in thread
From: Jeffrey A Law @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: Alexandre Oliva, egcs
In message < Pine.HPP.3.93.990612212649.14272E-100000@merle.acns.nwu.edu >you w
rite:
> I know something is broken, that's what I'm trying to figure out!! :)
Maybe I should have stated it differently -- something on your *system*
is busted, not egcs itself.
jeff
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:40 ` Sean R Melody
1999-06-12 16:49 ` Alexandre Oliva
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>
> > Perhaps I should clarify this further. If I g++ helloworld.cc, it will
> > compile and link,
>
> Which means it *is* linked with libstdc++.
Ahh..you're right...good point :)
>
> > but if you run it, it will segfault. If I use ldd to check what
> > libraries it is linked against, it does not include libstdc++.
>
> Looks like it's linked statically, with the wrong version of
> libstdc++. Look for libstdc++.a in the directories searched for
> libraries, and make sure it is not pointing to an old version of
> libstdc++.
Ok, I only have one libstdc*.a, and that is in /usr/lib, it is
libstdc++-2-libc6.1-1.2.9.a
/usr/lib/libstdc++.so is linked to /usr/lib/libstdc++-2-libc6.1-1.2.9.0.so
/usr/lib is first in /etc/ld.so.conf
Where should I go from here?
thanks again,
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:04 ` Sean R Melody
1999-06-12 17:46 ` Jeffrey A Law
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
>
> > On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> >> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> >> then, libstdc++ is not being linked into my c++ programs.
>
> > egcs doesn't link with libstdc++, only eg++ does.
> ^ I mean `g++' here
Ok, that's what I should have said, the g++ that comes with the egcs
package does not link with libstdc++.
Sean
>
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:49 ` Alexandre Oliva
1999-06-12 19:26 ` Sean R Melody
@ 1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 0 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> /usr/lib is first in /etc/ld.so.conf
This doesn't matter, lt.so.conf is only used by the run-time dynamic
linker. Run `g++ -v -Wl,-v' to re-link your program, and search for
libstdc++ in the directories that appear after -L options.
Make sure the libstdc++ links in
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-13 0:00 ` Sean R Melody
@ 1999-06-30 15:43 ` Sean R Melody
0 siblings, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
We have a winner!! :)
On 13 Jun 1999, Alexandre Oliva wrote:
> Now go look for libstdc++* in any of the directories that appear after
> -L in this list.
>
/usr/local/lib had a static library...thanks so much Alexandre and all
those who helped.
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:22 ` Alexandre Oliva
1999-06-12 16:40 ` Sean R Melody
@ 1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 0 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> Perhaps I should clarify this further. If I g++ helloworld.cc, it will
> compile and link,
Which means it *is* linked with libstdc++.
> but if you run it, it will segfault. If I use ldd to check what
> libraries it is linked against, it does not include libstdc++.
Looks like it's linked statically, with the wrong version of
libstdc++. Look for libstdc++.a in the directories searched for
libraries, and make sure it is not pointing to an old version of
libstdc++.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 17:46 ` Jeffrey A Law
1999-06-12 19:27 ` Sean R Melody
@ 1999-06-30 15:43 ` Jeffrey A Law
1 sibling, 0 replies; 30+ messages in thread
From: Jeffrey A Law @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: Alexandre Oliva, egcs
In message < Pine.HPP.3.93.990612180248.12408A-100000@merle.acns.nwu.edu >you w
rite:
> Ok, that's what I should have said, the g++ that comes with the egcs
> package does not link with libstdc++.
Huh? g++ has been linking in libstdc++ for years. We have not changed that
and we have no intention of changing that. If yours isn't linking in libstdc++,
then there's something majorly broken on your system.
jeff
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 22:41 ` Alexandre Oliva
1999-06-13 0:00 ` Sean R Melody
@ 1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 0 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> On 12 Jun 1999, Alexandre Oliva wrote:
>> search for libstdc++ in the directories that appear after -L
>> options. Make sure the libstdc++ links in
>> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
> Both the static and dynamic version are soft links to the /usr/lib
> libraries.
> /usr/bin/ld -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o
> /usr/lib/crti.o /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
> -L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
> -L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
> -L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
> -L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm
> -lgcc -lc -lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
> /usr/lib/crtn.o
Now go look for libstdc++* in any of the directories that appear after
-L in this list.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:11 ` Sean R Melody
1999-06-12 16:22 ` Alexandre Oliva
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
>
> > On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> >> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> >> then, libstdc++ is not being linked into my c++ programs.
>
> > egcs doesn't link with libstdc++, only eg++ does.
> ^ I mean `g++' here
>
Perhaps I should clarify this further. If I g++ helloworld.cc, it will
compile and link, but if you run it, it will segfault. If I use ldd to
check what libraries it is linked against, it does not include libstdc++.
The problem, it would appear, is different than Glenn Gebhart's problem.
Just FYI...
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 19:27 ` Sean R Melody
1999-06-12 23:15 ` Jeffrey A Law
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Jeffrey A Law; +Cc: Alexandre Oliva, egcs
On Sat, 12 Jun 1999, Jeffrey A Law wrote:
> In message < Pine.HPP.3.93.990612180248.12408A-100000@merle.acns.nwu.edu >you w
> rite:
> > Ok, that's what I should have said, the g++ that comes with the egcs
> > package does not link with libstdc++.
> Huh? g++ has been linking in libstdc++ for years. We have not changed that
> and we have no intention of changing that. If yours isn't linking in libstdc++,
> then there's something majorly broken on your system.
I know something is broken, that's what I'm trying to figure out!! :)
>
> jeff
>
>
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 19:26 ` Sean R Melody
1999-06-12 22:41 ` Alexandre Oliva
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>
> > /usr/lib is first in /etc/ld.so.conf
>
> This doesn't matter, lt.so.conf is only used by the run-time dynamic
> linker. Run `g++ -v -Wl,-v' to re-link your program, and search for
> libstdc++ in the directories that appear after -L options.
I've attached the output to the bottom of this email.
>
> Make sure the libstdc++ links in
> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
Both the static and dynamic version are soft links to the /usr/lib
libraries.
Here is the output (apologies for the length and the long lines...)
I don't know what is wrong, but hopefully someone else knows what to look
for.
Sean
lin088194:~/b30$ g++ -v -Wl,-v test.cc
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/cpp -lang-c++ -v -undef
-D__GNU
C__=2 -D__GNUG__=2 -D__cplusplus -D__GNUC_MINOR__=91 -D__ELF__ -Dunix
-Di386 -D_
_i386__ -Dlinux -D__ELF__ -D__unix__ -D__i386__ -D__i386__ -D__linux__
-D__unix-D__i386 -D__linux -Asystem(posix) -D__EXCEPTIONS -Asystem(unix)
-Acpu(i386) -Am
achine(i386) -Di386 -D__i386 -D__i386__ test.cc /tmp/ccHoxISg.ii
GNU CPP version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release) (i386
Linux/ELF
)
#include "..." search starts here:
#include <...> search starts here:
/usr/local/qt/include
/usr/include/g++-2
/usr/local/include
/usr/i386-redhat-linux/include
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/include
/usr/include
End of search list.
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/cc1plus /tmp/ccHoxISg.ii
-quiet
-dumpbase test.cc -version -o /tmp/ccqzXi8o.s
HInux) compiled by GNU C version egcs-2.91.66 19990314/Linux (egcs-1.1.2
release). as -V -Qy -o /tmp/cc38JZoP.o /tmp/ccqzXi8o.s
GNU assembler version 2.9.1 (i386-redhat-linux), using BFD version
2.9.1.0.23
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/collect2 -m elf_i386
-dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o /usr/lib/crti.o
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
-L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
-L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm -lgcc -lc
-lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
/usr/lib/crtn.o
collect2 version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release) (i386
Linux/ELF)
/usr/bin/ld -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o
/usr/lib/crti.o /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
-L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
-L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm
-lgcc -lc -lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
/usr/lib/crtn.o
GNU ld version 2.9.1 (with BFD 2.9.1.0.23)
^ permalink raw reply [flat|nested] 30+ messages in thread
* Changing Default Linking options...
1999-06-12 15:53 Sean R Melody
1999-06-12 15:55 ` Alexandre Oliva
@ 1999-06-30 15:43 ` Sean R Melody
1 sibling, 0 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-30 15:43 UTC (permalink / raw)
To: egcs
I recently upgraded my egcs when I installed redhat 6.0 and ever since
then, libstdc++ is not being linked into my c++ programs. How can I
change the default linking options so that libstdc++ is linked? I looked
at the specs file but couldn't understand it... :(
Thanks in Advance,
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:55 ` Alexandre Oliva
1999-06-12 15:58 ` Alexandre Oliva
@ 1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 0 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-30 15:43 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> then, libstdc++ is not being linked into my c++ programs.
egcs doesn't link with libstdc++, only eg++ does.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 22:41 ` Alexandre Oliva
@ 1999-06-13 0:00 ` Sean R Melody
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 1 reply; 30+ messages in thread
From: Sean R Melody @ 1999-06-13 0:00 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
We have a winner!! :)
On 13 Jun 1999, Alexandre Oliva wrote:
> Now go look for libstdc++* in any of the directories that appear after
> -L in this list.
>
/usr/local/lib had a static library...thanks so much Alexandre and all
those who helped.
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 19:27 ` Sean R Melody
@ 1999-06-12 23:15 ` Jeffrey A Law
1999-06-30 15:43 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1 sibling, 1 reply; 30+ messages in thread
From: Jeffrey A Law @ 1999-06-12 23:15 UTC (permalink / raw)
To: Sean R Melody; +Cc: Alexandre Oliva, egcs
In message < Pine.HPP.3.93.990612212649.14272E-100000@merle.acns.nwu.edu >you w
rite:
> I know something is broken, that's what I'm trying to figure out!! :)
Maybe I should have stated it differently -- something on your *system*
is busted, not egcs itself.
jeff
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 19:26 ` Sean R Melody
@ 1999-06-12 22:41 ` Alexandre Oliva
1999-06-13 0:00 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1 sibling, 2 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-12 22:41 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> On 12 Jun 1999, Alexandre Oliva wrote:
>> search for libstdc++ in the directories that appear after -L
>> options. Make sure the libstdc++ links in
>> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
> Both the static and dynamic version are soft links to the /usr/lib
> libraries.
> /usr/bin/ld -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o
> /usr/lib/crti.o /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
> -L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
> -L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
> -L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
> -L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm
> -lgcc -lc -lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
> /usr/lib/crtn.o
Now go look for libstdc++* in any of the directories that appear after
-L in this list.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 17:46 ` Jeffrey A Law
@ 1999-06-12 19:27 ` Sean R Melody
1999-06-12 23:15 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Jeffrey A Law
1 sibling, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 19:27 UTC (permalink / raw)
To: Jeffrey A Law; +Cc: Alexandre Oliva, egcs
On Sat, 12 Jun 1999, Jeffrey A Law wrote:
> In message < Pine.HPP.3.93.990612180248.12408A-100000@merle.acns.nwu.edu >you w
> rite:
> > Ok, that's what I should have said, the g++ that comes with the egcs
> > package does not link with libstdc++.
> Huh? g++ has been linking in libstdc++ for years. We have not changed that
> and we have no intention of changing that. If yours isn't linking in libstdc++,
> then there's something majorly broken on your system.
I know something is broken, that's what I'm trying to figure out!! :)
>
> jeff
>
>
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:49 ` Alexandre Oliva
@ 1999-06-12 19:26 ` Sean R Melody
1999-06-12 22:41 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 19:26 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>
> > /usr/lib is first in /etc/ld.so.conf
>
> This doesn't matter, lt.so.conf is only used by the run-time dynamic
> linker. Run `g++ -v -Wl,-v' to re-link your program, and search for
> libstdc++ in the directories that appear after -L options.
I've attached the output to the bottom of this email.
>
> Make sure the libstdc++ links in
> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
Both the static and dynamic version are soft links to the /usr/lib
libraries.
Here is the output (apologies for the length and the long lines...)
I don't know what is wrong, but hopefully someone else knows what to look
for.
Sean
lin088194:~/b30$ g++ -v -Wl,-v test.cc
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/cpp -lang-c++ -v -undef
-D__GNU
C__=2 -D__GNUG__=2 -D__cplusplus -D__GNUC_MINOR__=91 -D__ELF__ -Dunix
-Di386 -D_
_i386__ -Dlinux -D__ELF__ -D__unix__ -D__i386__ -D__i386__ -D__linux__
-D__unix-D__i386 -D__linux -Asystem(posix) -D__EXCEPTIONS -Asystem(unix)
-Acpu(i386) -Am
achine(i386) -Di386 -D__i386 -D__i386__ test.cc /tmp/ccHoxISg.ii
GNU CPP version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release) (i386
Linux/ELF
)
#include "..." search starts here:
#include <...> search starts here:
/usr/local/qt/include
/usr/include/g++-2
/usr/local/include
/usr/i386-redhat-linux/include
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/include
/usr/include
End of search list.
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/cc1plus /tmp/ccHoxISg.ii
-quiet
-dumpbase test.cc -version -o /tmp/ccqzXi8o.s
HInux) compiled by GNU C version egcs-2.91.66 19990314/Linux (egcs-1.1.2
release). as -V -Qy -o /tmp/cc38JZoP.o /tmp/ccqzXi8o.s
GNU assembler version 2.9.1 (i386-redhat-linux), using BFD version
2.9.1.0.23
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/collect2 -m elf_i386
-dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o /usr/lib/crti.o
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
-L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
-L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm -lgcc -lc
-lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
/usr/lib/crtn.o
collect2 version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release) (i386
Linux/ELF)
/usr/bin/ld -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o
/usr/lib/crti.o /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtbegin.o
-L/usr/local/qt/lib -L/usr/local/kde/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/local/qt/lib -L/usr/local/lib
-L/usr/local/rvplayer -L/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66
-L/usr/i386-redhat-linux/lib -v /tmp/cc38JZoP.o -lstdc++ -lm
-lgcc -lc -lgcc /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66/crtend.o
/usr/lib/crtn.o
GNU ld version 2.9.1 (with BFD 2.9.1.0.23)
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:04 ` Sean R Melody
@ 1999-06-12 17:46 ` Jeffrey A Law
1999-06-12 19:27 ` Sean R Melody
1999-06-30 15:43 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1 sibling, 2 replies; 30+ messages in thread
From: Jeffrey A Law @ 1999-06-12 17:46 UTC (permalink / raw)
To: Sean R Melody; +Cc: Alexandre Oliva, egcs
In message < Pine.HPP.3.93.990612180248.12408A-100000@merle.acns.nwu.edu >you w
rite:
> Ok, that's what I should have said, the g++ that comes with the egcs
> package does not link with libstdc++.
Huh? g++ has been linking in libstdc++ for years. We have not changed that
and we have no intention of changing that. If yours isn't linking in libstdc++,
then there's something majorly broken on your system.
jeff
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:40 ` Sean R Melody
@ 1999-06-12 16:49 ` Alexandre Oliva
1999-06-12 19:26 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1 sibling, 2 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-12 16:49 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> /usr/lib is first in /etc/ld.so.conf
This doesn't matter, lt.so.conf is only used by the run-time dynamic
linker. Run `g++ -v -Wl,-v' to re-link your program, and search for
libstdc++ in the directories that appear after -L options.
Make sure the libstdc++ links in
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.91.66 are correct.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:22 ` Alexandre Oliva
@ 1999-06-12 16:40 ` Sean R Melody
1999-06-12 16:49 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 16:40 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>
> > Perhaps I should clarify this further. If I g++ helloworld.cc, it will
> > compile and link,
>
> Which means it *is* linked with libstdc++.
Ahh..you're right...good point :)
>
> > but if you run it, it will segfault. If I use ldd to check what
> > libraries it is linked against, it does not include libstdc++.
>
> Looks like it's linked statically, with the wrong version of
> libstdc++. Look for libstdc++.a in the directories searched for
> libraries, and make sure it is not pointing to an old version of
> libstdc++.
Ok, I only have one libstdc*.a, and that is in /usr/lib, it is
libstdc++-2-libc6.1-1.2.9.a
/usr/lib/libstdc++.so is linked to /usr/lib/libstdc++-2-libc6.1-1.2.9.0.so
/usr/lib is first in /etc/ld.so.conf
Where should I go from here?
thanks again,
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 16:11 ` Sean R Melody
@ 1999-06-12 16:22 ` Alexandre Oliva
1999-06-12 16:40 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1 sibling, 2 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-12 16:22 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> Perhaps I should clarify this further. If I g++ helloworld.cc, it will
> compile and link,
Which means it *is* linked with libstdc++.
> but if you run it, it will segfault. If I use ldd to check what
> libraries it is linked against, it does not include libstdc++.
Looks like it's linked statically, with the wrong version of
libstdc++. Look for libstdc++.a in the directories searched for
libraries, and make sure it is not pointing to an old version of
libstdc++.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:58 ` Alexandre Oliva
1999-06-12 16:04 ` Sean R Melody
@ 1999-06-12 16:11 ` Sean R Melody
1999-06-12 16:22 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
2 siblings, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 16:11 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
>
> > On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> >> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> >> then, libstdc++ is not being linked into my c++ programs.
>
> > egcs doesn't link with libstdc++, only eg++ does.
> ^ I mean `g++' here
>
Perhaps I should clarify this further. If I g++ helloworld.cc, it will
compile and link, but if you run it, it will segfault. If I use ldd to
check what libraries it is linked against, it does not include libstdc++.
The problem, it would appear, is different than Glenn Gebhart's problem.
Just FYI...
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:58 ` Alexandre Oliva
@ 1999-06-12 16:04 ` Sean R Melody
1999-06-12 17:46 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1999-06-12 16:11 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
2 siblings, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 16:04 UTC (permalink / raw)
To: Alexandre Oliva; +Cc: egcs
On 12 Jun 1999, Alexandre Oliva wrote:
> On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
>
> > On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> >> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> >> then, libstdc++ is not being linked into my c++ programs.
>
> > egcs doesn't link with libstdc++, only eg++ does.
> ^ I mean `g++' here
Ok, that's what I should have said, the g++ that comes with the egcs
package does not link with libstdc++.
Sean
>
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:55 ` Alexandre Oliva
@ 1999-06-12 15:58 ` Alexandre Oliva
1999-06-12 16:04 ` Sean R Melody
` (2 more replies)
1999-06-30 15:43 ` Alexandre Oliva
1 sibling, 3 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-12 15:58 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
> On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
>> I recently upgraded my egcs when I installed redhat 6.0 and ever since
>> then, libstdc++ is not being linked into my c++ programs.
> egcs doesn't link with libstdc++, only eg++ does.
^ I mean `g++' here
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Re: Changing Default Linking options...
1999-06-12 15:53 Sean R Melody
@ 1999-06-12 15:55 ` Alexandre Oliva
1999-06-12 15:58 ` Alexandre Oliva
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1 sibling, 2 replies; 30+ messages in thread
From: Alexandre Oliva @ 1999-06-12 15:55 UTC (permalink / raw)
To: Sean R Melody; +Cc: egcs
On Jun 12, 1999, Sean R Melody <srm765@merle.acns.nwu.edu> wrote:
> I recently upgraded my egcs when I installed redhat 6.0 and ever since
> then, libstdc++ is not being linked into my c++ programs.
egcs doesn't link with libstdc++, only eg++ does.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
{oliva,Alexandre.Oliva}@dcc.unicamp.br aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
*** E-mail about software projects will be forwarded to mailing lists
^ permalink raw reply [flat|nested] 30+ messages in thread
* Changing Default Linking options...
@ 1999-06-12 15:53 Sean R Melody
1999-06-12 15:55 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
0 siblings, 2 replies; 30+ messages in thread
From: Sean R Melody @ 1999-06-12 15:53 UTC (permalink / raw)
To: egcs
I recently upgraded my egcs when I installed redhat 6.0 and ever since
then, libstdc++ is not being linked into my c++ programs. How can I
change the default linking options so that libstdc++ is linked? I looked
at the specs file but couldn't understand it... :(
Thanks in Advance,
Sean
^ permalink raw reply [flat|nested] 30+ messages in thread
end of thread, other threads:[~1999-06-30 15:43 UTC | newest]
Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-06-12 22:39 Changing Default Linking options N8TM
1999-06-30 15:43 ` N8TM
-- strict thread matches above, loose matches on Subject: below --
1999-06-12 15:53 Sean R Melody
1999-06-12 15:55 ` Alexandre Oliva
1999-06-12 15:58 ` Alexandre Oliva
1999-06-12 16:04 ` Sean R Melody
1999-06-12 17:46 ` Jeffrey A Law
1999-06-12 19:27 ` Sean R Melody
1999-06-12 23:15 ` Jeffrey A Law
1999-06-30 15:43 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Jeffrey A Law
1999-06-30 15:43 ` Sean R Melody
1999-06-12 16:11 ` Sean R Melody
1999-06-12 16:22 ` Alexandre Oliva
1999-06-12 16:40 ` Sean R Melody
1999-06-12 16:49 ` Alexandre Oliva
1999-06-12 19:26 ` Sean R Melody
1999-06-12 22:41 ` Alexandre Oliva
1999-06-13 0:00 ` Sean R Melody
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Alexandre Oliva
1999-06-30 15:43 ` Sean R Melody
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).