This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Trouble with -frepo -fnew-abi and unresolved symbols


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            |
+-----------------------------------------------------------------------+


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]