Martin Marques wrote:
Yes. Unpack gpc sources, make sure that p subdirectory from gpc source tree appears as gcc-4.1.2/gcc/p is gcc source tree (either use move or a symlink), configure and make.
Didn't work. :-(
make[2]: se ingresa al directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925/host-x86_64-unknown-linux-gnu/gcc' gcc -c -g -O2 -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute -DHAVE_CONFIG_H -I. -I. -I../.././gcc -I../.././gcc/. -I../.././gcc/../include -I../.././gcc/../libcpp/include ../.././gcc/dbxout.c -o dbxout.o ../.././gcc/dbxout.c: In function ?dbxout_type?: ../.././gcc/dbxout.c:1978: error: ?have_used_extensions? no se declaró aquí (primer uso en esta función) ../.././gcc/dbxout.c:1978: error: (Cada identificador no declarado solamente se reporta una vez ../.././gcc/dbxout.c:1978: error: ara cada funcion en la que aparece.) make[2]: *** [dbxout.o] Error 1 make[2]: se sale del directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925/host-x86_64-unknown-linux-gnu/gcc' make[1]: *** [all-gcc] Error 2 make[1]: se sale del directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925' make: *** [all] Error 2
Any ideas?
Do you really use use gcc-4.1.2? The name gcc-4.1.2-20070925 indicates that you have different version. IIRC the patch /usr/src/redhat/BUILD/ is was used for Redhat modified sources, which are usually different than official version.
I would suggest to try to use unmodified gcc-4.1.2. If for some reason you need to use RedHat/Fedora specific version, please make sure first that you can compile gcc alone -- without gpc.
Concerning the error message: it tells you that the identifier 'have_used_extensions' is undefined. AFAICS this identifier does not apper in gcc-4.1.2 (change log claims that it was removed in 2005). Gpc patches some gcc files, but the patch also does not contain it. So I think that you get message about 'have_used_extensions' because your 'gcc-4.1.2-20070925' is a modified version and that the modification contains error.
Waldek Hebisch escribiĂł:
Martin Marques wrote:
Yes. Unpack gpc sources, make sure that p subdirectory from gpc source tree appears as gcc-4.1.2/gcc/p is gcc source tree (either use move or a symlink), configure and make.
Didn't work. :-(
make[2]: se ingresa al directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925/host-x86_64-unknown-linux-gnu/gcc' gcc -c -g -O2 -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -pedantic -Wno-long-long -Wno-variadic-macros -Wold-style-definition -Wmissing-format-attribute -DHAVE_CONFIG_H -I. -I. -I../.././gcc -I../.././gcc/. -I../.././gcc/../include -I../.././gcc/../libcpp/include ../.././gcc/dbxout.c -o dbxout.o ../.././gcc/dbxout.c: In function ?dbxout_type?: ../.././gcc/dbxout.c:1978: error: ?have_used_extensions? no se declarĂł aquĂ (primer uso en esta funciĂłn) ../.././gcc/dbxout.c:1978: error: (Cada identificador no declarado solamente se reporta una vez ../.././gcc/dbxout.c:1978: error: ara cada funcion en la que aparece.) make[2]: *** [dbxout.o] Error 1 make[2]: se sale del directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925/host-x86_64-unknown-linux-gnu/gcc' make[1]: *** [all-gcc] Error 2 make[1]: se sale del directorio `/usr/src/redhat/BUILD/gcc-4.1.2-20070925' make: *** [all] Error 2
Any ideas?
Do you really use use gcc-4.1.2? The name gcc-4.1.2-20070925 indicates that you have different version. IIRC the patch /usr/src/redhat/BUILD/ is was used for Redhat modified sources, which are usually different than official version.
I would suggest to try to use unmodified gcc-4.1.2. If for some reason you need to use RedHat/Fedora specific version, please make sure first that you can compile gcc alone -- without gpc.
Concerning the error message: it tells you that the identifier 'have_used_extensions' is undefined. AFAICS this identifier does not apper in gcc-4.1.2 (change log claims that it was removed in 2005). Gpc patches some gcc files, but the patch also does not contain it. So I think that you get message about 'have_used_extensions' because your 'gcc-4.1.2-20070925' is a modified version and that the modification contains error.
OK, downloaded gcc-4.1.2 from the gnu.org site and I get the same error.
One thing I forgot to mention is that the first configure tells me I have to patch gcc, and the gpc s only compatible with 3.4.x versions of gcc while I have 4.1.2:
*** *** Detected GCC version 4.1.2. *** The GPC port for GCC > 4.0.x does not work. *** You can proceed now if you want to work on it. *** *** For a "production compiler" we currently still *** recommend GPC based on gcc 3.3.x or gcc 3.4.x *** *** Press ENTER to continue, Ctrl-C to abort. ***
I pressed enter and got this:
*** *** Detected GCC version 4.1.2. *** This version of GPC requires one of the following versions of the GCC *** sources to build: *** *** 2.8.1 *** 2.95.1 *** 2.95.2 *** 2.95.3-5 *** 2.95.3-6 *** 2.95.3-8 *** 2.95.3 *** 2.95.4 *** 2.95 *** 3.2.1 *** 3.2.2 *** 3.2.3 *** 3.3.3 *** 3.3.4 *** 3.3.5 *** 3.3.6 *** 3.4.3 *** 3.4.4 *** 3.4.5 *** 3.4.6 *** 4.0.2 *** 4.0.3 *** *** (You can try to patch GCC manually by changing to the directory *** /usr/src/redhat/BUILD/gcc-4.1.2/gcc, *** typing a command like `patch -p1 < p/diffs/gcc-<version>.diff' and patching *** possible rejects by hand before you run the configure script again.) ***
I tried patching with the 4.0.3 version, but got lots of hunks that didn't get applied.
Is there a newer version of gpc? I got 20060325.
Martin Marques wrote:
Waldek Hebisch escribió: OK, downloaded gcc-4.1.2 from the gnu.org site and I get the same error.
One thing I forgot to mention is that the first configure tells me I have to patch gcc, and the gpc s only compatible with 3.4.x versions of gcc while I have 4.1.2:
<snip>
I tried patching with the 4.0.3 version, but got lots of hunks that didn't get applied.
Is there a newer version of gpc? I got 20060325.
I see. gpc-20060325 does not work with gcc-4.1.x. To work with gcc-4.1.x one needs more changes than 4.0.3 patch (actually parts of this patch may be charmful for gcc-4.1.x). To work with gcc-4.1.x you need the newest gpc version: gpc-20070904. You can get it form:
http://www.math.uni.wroc.pl/~hebisch/gpc/gpc-20070904.tar.bz2
Waldek Hebisch escribiĂł:
I see. gpc-20060325 does not work with gcc-4.1.x. To work with gcc-4.1.x one needs more changes than 4.0.3 patch (actually parts of this patch may be charmful for gcc-4.1.x). To work with gcc-4.1.x you need the newest gpc version: gpc-20070904. You can get it form:
http://www.math.uni.wroc.pl/~hebisch/gpc/gpc-20070904.tar.bz2
Great, got it working, now some doubts that arised:
1) Why isn't the 20070904 version linked in the gpc page? 2) I have to add the --disable-multilib to make it compile. gpc doesn't support multilib yet?
Martin Marques wrote:
Great, got it working, now some doubts that arised:
- Why isn't the 20070904 version linked in the gpc page?
The gpc website is maintained separately...
- I have to add the --disable-multilib to make it compile. gpc doesn't
support multilib yet?
Right. Currently gpc does not support multilib enabled build.