Article View: gnu.gcc.help
Article #419Re: Help with gcc-2.2.2 on ATT 3b2!!!!
From: Gregory Gulik
Date: Mon, 14 Sep 1992 17:42
Date: Mon, 14 Sep 1992 17:42
109 lines
4217 bytes
4217 bytes
In article <2539.2ab25475@vger.nsu.edu> a_sudan@vger.nsu.edu writes:
>Hi,
>This is the 4th request so I hope to get some
>response. I am trying to build gcc-2.2.2 on an
>ATT 3b2, SYSVr3.2. The problem as I try to issue
>make LANGUAGES=c I am recieving a too much defining
>error in stmt.c . I know that there is a fix in the
>Makefile but I can't handle this on my own. So.....
>someone out there if you can oblige me with this fix
>I would greatly appreciate it.
>
>Also any other hints recommendations on building gcc and
>g++ would be appreciated.
The 3B2 FAQ I post to comp.sys.att monthly covers this subject. Below
is the relavent section:
------------------------------------------------------------------------------
Subject: 12 How do I build GCC on the 3B2?
------------------------------------------------------------------------------
John L. Wehle ported GCC to the WE32000 series processor, and it
first appeared in release 2.2 of GCC.
To build the GCC release on the 3B2, download the latest GCC
distribution and allocate at least 35 MB of disk space to do the
build. Follow the directions in the INSTALL file. The following
are some notes that will make the install go smoother.
First of all, older versions of /lib/cpp are not capable of
processing one of the source files. I recommend building the
distribution until the GNU cpp is done. Then, temporarily replace
your /lib/cpp with the GNU version, and add the following flag to
CFLAGS:
CFLAGS = -U__STDC__
When stage1 is complete, you could remove the -U__STDC__ flag
and restore your original cpp.
Basically, the steps are as follows:
$ configure --target=we32k-att-sysv3
$ make LANGUAGES=c
$ make stage1
$ make LANGUAGES=c CC=stage1/gcc CFLAGS="-Bstage1/ -g"
[It is imporant to note that due to a bug in the AT&T compiler,
the optimizer doesn't get compiled correctly at this point.]
$ make stage2
$ make CC=stage2/gcc CFLAGS="-Bstage2/ -g -O"
[Some people still have problems with the optimizer at this point.
If you do, just do not use the -O flag when compiling GCC. The
symptom you will experience that tells you the -O flag should be
removed is the compilation of cccp.c will take a VERY long time.
Kill the compile and restart without the -O.]
$ make stage3
$ make CC=stage3/gcc CFLAGS="-Bstage3/ -g -O"
To verify everything built correctly:
$ for file in *.o; do
> tail +10c $file > foo1
> tail +10c stage3/$file > foo2
> cmp foo1 foo2 || echo $file
> done
Then, to install the distribution:
$ make CC=stage3/gcc CFLAGS="-Bstage3/ -g -O" install
Good luck!
[These notes are a combination of my own experiences with building the
GCC compiler on a 3B2/400 and discussions with John Wehle, the author
of the port.]
NOTES:
The GCC binaries available on several anonymous FTP sites will not
work with certain version of the standard C compiler. It appears
to be some sort of linker problem.
Speaking of linker problems, GCC will not work all that well with
the standard C shared library -lc_s. The workaround for this is
to compile your program with GCC, but the link will fail. When it
does, use something like the following to do the link stage:
$ cc -O -L/usr/local/lib/gcc-lib/we32k-att-sysv/2.2.2 program.o \
-o program -lgcc -lc_s
This way, you will not only get fast binaries, but small ones as
well.
You may need to raise your ULIMIT to compile the g++ compiler as
the executable is larger than 1 MB.
-greg
--
Gregory A. Gulik Call Gagme, a public access
greg@serveme.chi.il.us UNIX system at 312-282-8606
|| gulik@rtsg.mot.com For information, drop a note
to info@gagme.chi.il.us
Technical Details
Message-ID:
<1992Sep14.174211.2238@serveme.chi.il.us>Path:
arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!rutgers!mcdchg!serveme!gagme!gregReferences:
<2539.2ab25475@vger.nsu.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!rutgers!mcdchg!serveme!gagme!greg From: greg@serveme.chi.il.us (Gregory Gulik) Newsgroups: gnu.gcc.help Subject: Re: Help with gcc-2.2.2 on ATT 3b2!!!! Message-ID: <1992Sep14.174211.2238@serveme.chi.il.us> Date: 14 Sep 92 17:42:11 GMT References: <2539.2ab25475@vger.nsu.edu> Organization: Gagme Public Access Unix, Chicago, Illinois Lines: 109