Compiling gcc-3.2.2 for IRIX

| 4 Comments

I mentioned this in the forum, but figured it's worth repeating here for those who don't venture there.

I discovered a nasty bug with gcc-3.2.1 (g++/C++ specifically) which made it useless for even those running 6.5.18 and up. Yes, once again an issue with the new header structure; a 'configure' option was left off that generates unresolvable errors during C++ compiles.

gcc-3.2.2 was released earlier this month so I decided to take advantage of the situation and repair my gcc-3.2.1 SGI Freeware version. It was pretty easy to get going once I gleaned the proper 'configure' info from the gcc mailing list.

You can use your existing gcc version to bootstrap 3.2.2 (SGI's 3.2.1 will work for this purpose), or MIPSPro if you have it.

To build under IRIX 6.5.18 and up:

Untar and cd to gcc-3.2.2:

./configure --prefix=/usr/freeware --enable-version-specific-runtime-libs --enable-threads --enable-haifa --disable-c-mbchar --disable-shared

gmake bootstrap

then as root:

gmake install

[Mika:~] neko 105% gcc -v
Reading specs from /usr/freeware/lib/gcc-lib/mips-sgi-irix6.5/3.2.2/specs
Configured with: ./configure --prefix=/usr/freeware --enable-version-specific-runtime-libs --enable-threads --enable-haifa --disable-c-mbchar --disable-shared
Thread model: single
gcc version 3.2.2

To build under IRIX 6.5.17 and below:

Use the same method, just leave off the --disable-c-mbchar switch on the configure line, though leaving it on probably won't hurt anything.

I could package this into a tardist, but of course it would only work with IRIX 6.5.18 and up due to the header differences.

4 Comments

Does it support n32/n64?

Of course. You would need to add '--disable-multilib' to the configure line to disable 64-bit on an IRIX64 target.

You mean we can produce n32 and n64 binaries?
If so, it's wonderful, I thought gcc was only
capable of producing o32 binaries, do we have
a description of n32/n64 ELF binary format?
I'd like to understand exactly how n32/n64
binaries work.

gcc by default does n32, it can do 64-bit with a simple -mabi=64 switch on the compile line. It's been a long, long while since -o32 was default for gcc.

About this Entry

This page contains a single entry by nekonoko published on February 17, 2003 3:09 AM.

Beta release of Java2 v1.4.1 APIs for IRIX 6.5 was the previous entry in this blog.

Blender 2.26 Released is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.