Hi Andrew, Here's the relevant bit from the website I referenced: *** GCC 2.95.x About half of the changes needed for GCC 3.0.x are also applicable here (e.g. Makefile fixes, lib32 fix-ups, spec flags, etc). Unfortunately, the other half are workarounds for compiler and glibc nuances that are fixed in later releases. One of the big changes needed is a workaround for the internal use of an _IO_MTSAFE_IO define. This define causes an error due to a missing header due to difference in glibc headers included with modern Linux distributions (see here and here for more info). Luckily, a straightforward workaround is to use glibc's generic stdio-lock.h header, which in my case needed to be pulled from the glibc 2.10.1 source to match my installed version. Additionally, another glibc fix is required due to an unnamed union declaration (see this bug) inside a pthread header which is not supported by GCC 2.95.x. To workaround the issue I pulled in the glibc 2.10.1 system dependent pthreadtypes.h header from the source and appended a variable name (e.g. __gcc_295_workaround__) to the unnamed union declaration. Build this version using the provided patch @ (gcc-v2.95.x.debian.x86_64.diff) and the following instructions: # shell commands tar xzf glibc-2.10.1.tar.gz mkdir -p gcc-2.95.3/glibc-workaround/include/bits cp glibc-2.10.1/bits/stdio-lock.h gcc-2.95.3/glibc-workaround/include/bits cp glibc-2.10.1/nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h gcc-2.95.3/glibc-workaround/include/bits sed -i -n '1h;1!H;${;g;s/\(__pthread_slist_t __list;\n[ \t]*}\)/\1 __gcc_295_workaround__/g;p;}' gcc-2.95.3/glibc-workaround/include/bits/pthreadtypes.h tar xzf gcc-2.95.3.tar.gz cd gcc-2.95.3 patch -p0 < gcc-v2.95.x.debian.x86_64.diff mkdir ../gcc-2.95.3-objdir cd ../gcc-2.95.3-objdir ../gcc-2.95.3/configure --prefix=/opt/i386/gcc/gcc-2.95.3 --enable-languages=c,c++ --enable-threads=posix --enable-shared --host i386-pc-linux-gnu make make install *** I also attached my logs: gcc295.log / gcc295.err in plain text. If you have any success compiling GCC 2.95 on your own without using the method above please let me know too! Thank you, Roman.
Attachment:
gcc-v2.95.x.debian.x86_64.diff
Description: Binary data
Attachment:
gcc295.err
Description: Binary data
Attachment:
gcc295.log
Description: Binary data
On 03-Apr-2012, at 6:17 , Andrew Haley wrote: > On 04/02/2012 06:29 PM, Roman Suvorov wrote: >> The URL above contains a link to my stdout/stderr logs too. > > That thing wants me to use flash. I don't use flash. > > Andrew.