This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
egcs-19980517, i586-linux-gnu: Trouble with _IO_getline_info
- To: egcs-bugs at cygnus dot com
- Subject: egcs-19980517, i586-linux-gnu: Trouble with _IO_getline_info
- From: Horst von Brand <vonbrand at sleipnir dot valparaiso dot cl>
- Date: Thu, 28 May 1998 23:17:24 -0500
This is i586-redhat-linux,linux-2.1.104-1, glibc-2.0.94, binutils-2.9.1.0.6.
Note that not all of the pieces where built in this environment!
When I try to compile a standard C++ program:
#include <iostream>
main()
{
cout << "Hello, world!" << endl;
return 0;
}
I get the following:
[root@sleipnir /tmp]# c++ hello.cc
/usr/lib/libstdc++.so: undefined reference to `_IO_getline_info@@GLIBC_2.1'
collect2: ld returned 1 exit status
When I run the collect2 command gcc invokes, but substituting "-static
-lstdc++ -dynamic" for "-lstdc++", the problem goes away and the program
runs as it should.
What is going on here? Operator fault (very possible)? How come the C++
testcases in the compiler worked?! (No, not _really_ important to me, I use
C most of the time anyway, and might as well wait a week for the next
snapshot... (the library built with 19980525 shows the same problem) ;)
Thanks!
--
Horst von Brand vonbrand@sleipnir.valparaiso.cl
Casilla 9G, Viņa del Mar, Chile +56 32 672616