[gnu.g++.bug] g++ on i386-sysv, install problem.

weave@sun.acs.udel.edu (Ken Weaverling) (02/20/90)

I am having a hard time getting g++ installed on a Prime EXL running
Sys V/386 3.1.  Everything works fine during compiles and install, but
when I try and compile and load a small g++ program, ld dumps core with
a bus error. (This same program compiles and loads fine on a sun...)

Specs and various details:
 
Prime EXL 325 running Sys V/386 3.1
gcc 1.37
g++ 1.36.3
libg++ 1.36.3

I am NOT using COFF_ENCAPSULATION (more on this later)
I am not using gas
gcc compiles and runs without a hitch
g++ compiles with the following changes...
   NO_DOLLAR_IN_LABEL defined in tm-att386.h
   Using malloc.c since a g++ compile dumped core and sdb said the culprit
      was malloc(). After I included malloc.c, g++ didn't dump core
   defined bcopy inside malloc.c
   Changed g++-include/stdio.h define for IOBUF_FLAG_TYPE to char as per
      a recommendation posted in this newsgroup
   Changed g++-inclide/math.h define for HUGE to MAXFLOAT as per a 
      recommendation posted in this newsgroup
   <sys/time.h> not found so I linked it to <sys/bsd_time.h>
   Used -DCOFF and -DUSE_COLLECT (EXTENDED_COFF won't compile collect.c)
   Used -DFASCIST_ASSEMBLER

Symptom of crash:
 
g++ compiles program, assembles output fine, but on final call to ld to
write output file, ld dumps core. (the standard system ld)
 
What I've tried:
 
Tried to install binutils so I could use COFF_ENCAPSULATION, gas, and
off course, gnu-ld. This works somewhat, but ld complains about 
/lib/crt1.o being malformed. I tried to convert crt1.o with robotussin
and it gave the following msg: Oops! possible bug - reloc reference
to ignored symbol, and then failed to convert the file.
 
Tried using collect2.c instead of collect.c which worked after I
altered the ASM_OUTPUT defines from ds.w to .label and .value however
ld would still dump core.

Moving alloca from libPW.a to libc.a

Attempted to compile ld.c (for ld++) in g++ but it complained about
missing <sys/resource.h> file. 
 
What I haven't tried:
 
Voting Republican
 
Standard plea:
 
HELP!!!