ld: internal error:

Ovidiu Toader ovi@physics.utoronto.ca
Sun Jan 11 09:47:00 GMT 1998


albatros:~/bug/bug5> uname -a
FreeBSD albatros.physics.utoronto.ca 3.0-971022-SNAP FreeBSD
3.0-971022-SNAP #0: Tue Dec 16 18:40:25 EST 1997    
ovi@albatros.physics.utoronto.ca:/usr/src/sys/compile/MYKERNEL_SMP  i386

albatros:~/bug/bug5> egcs_g++ -v
Reading specs from
/usr/local/egcs/lib/gcc-lib/i386-unknown-freebsd3.0/egcs-2.90.23/specs
gcc version egcs-2.90.23 980102 (egcs-1.0.1 release)

albatros:~/bug/bug5> cat bug.cc
#include <iostream.h>
class A{
public:
  ~A();
  A & operator=(A const &);
};
A::~A(){}
A & A::operator=(A const &right){
  cout << "cucu";
  return *this;
}

A glob;

int
main(){}

albatros:~/bug/bug5> egcs_g++ -O3 -o exe bug.cc
ld: internal error: allocated set symbol space (2) doesn't match actual
(6)
collect2: ld returned 1 exit status

	A very simple and meaningless program. The problem seems to be in the
linker. -O2 works fine and g++ (2.7.2.1) has no problems at -O3. I
wonder if on other architectures this program creates some sort of
problems.

	Thanks!
 
-- 
         Ovidiu



More information about the Gcc-bugs mailing list