This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Trouble with -frepo -fnew-abi and unresolved symbols
- To: egcs at cygnus dot com
- Subject: Trouble with -frepo -fnew-abi and unresolved symbols
- From: Matthias Mueller <matthias at ica1 dot uni-stuttgart dot de>
- Date: Fri, 4 Sep 1998 19:08:27 +0200 (MET DST)
Hi,
at the moment I try to compile my own C++ program with egcs-1.1.
I try it with -fnew-abi because otherwise I get problems with
VERY long symbols due to template expression programming. native 'as' simly
refuses to work and I want to use my dec alpha machine ( no gas in
binutils, at least last time I tried).
With -fnew-abi symbols seem to be short enough (great). But now I have
a problem with missing symbols.
The following example demonstrates the problem:
#include <string>
using namespace std;
int main(void)
{
string string1("hallo");
string string2("hallo");
if(string1==string2)
{
return 0;
}
return 1;
}
> g++ -c string_compare.cc -g -Wall -MMD -ansi -pedantic -frepo -fnew-abi
> g++ -g -Wall -MMD -ansi -pedantic -frepo string_compare.o -fnew-abi
collect: recompiling string_compare.cc
collect: relinking
/bin/ld:
Unresolved:
string_char_traits<char>::compare(char const *, char const *, unsigned long)
exception virtual table
terminate(void)
exception type_info function
exception type_info node
collect2: ld returned 1 exit status
I tried also to build the library with -fnew-abi by using:
make -k CFLAGS='-g -O' CXXFLAGS='-g -O' LIBCFLAGS='-g -O2' LIBCXXFLAGS='-g -O2 -fno-implicit-templates -fnew-abi' bootstrap
or even
make CFLAGS='-g -O -fnew-abi' CXXFLAGS='-g -O -fnew-abi' LIBCFLAGS='-g -O2 -fnew-abi' LIBCXXFLAGS='-g -O2 -fno-implicit-templates -fnew-abi' bootstrap
What's my mistake ?
Thanks,
Matthias
--
+-----------------------------------------------------------------------+
| Matthias Mueller matthias@ica1.uni-stuttgart.de |
| http://www.ica1.uni-stuttgart.de/~matthias |
+-----------------------------------------------------------------------+
| ICA 1, Pfaffenwaldring 27, D-70569 Stuttgart (Germany) |
| Tel. 49-(0)711/685-7606, Fax. 49-(0)711/685-3658 |
+-----------------------------------------------------------------------+