Re: [Inkscape-devel] gcc 3.3 bug: configure -Wno-pointer-sign test uses wrong compiler

jiho wrote
looking into compiling Inkscape on Mac OS X 10.3 an error appeared which is apparently not limited to OS X but more generally to old gcc versions (3.3 is used here). John Faith, the investigator of these issues, submitted a patch to configure.ac which fixes this. I am not knowledgeable enough with autoconf to review this. Could someone knowledgeable have a look at it and commit it or give me a go to commit this?
Hello, I was curious if anyone had a chance to think about this bug or if anyone had a minute to try a quick experiment.
In configure.ac, there is a block used to check if gcc can use -Wno-pointer-sign in CFLAGS. Unfortunately, the "AC_LANG(g++)" means that g++ is used for this compile test when gcc should be used, CLFLAGS is ignored, and the test always passes. For gcc4 this doesn't matter, but this breaks gcc3 when building in src/libcroco.
If anyone with gcc 3 or 4 could try a reconfigure, that would be helpful to see if this fixes other environments with gcc <4 and also does not break gcc4. Adding "AC_LANG_PUSH(C)" and "AC_LANG_POP" around the AC_COMPILE_IFELSE in configure.ac seems to fix this problem (see attached patch which is also in tracker #1702352). I've tried this patch on gcc3.3 OS 10.3.9.
After changing configure.ac, run ./autogen.sh then ./configure. For gcc<4, the final bit of configure output should not have -Wno-pointer-sign in CFLAGS.
Thanks in advance! , John

[I'm resending this since the mail was archived on Sourceforge, but apparently not sent.]
jiho wrote:
looking into compiling Inkscape on Mac OS X 10.3 an error appeared which is apparently not limited to OS X but more generally to old gcc versions (3.3 is used here). John Faith, the investigator of these issues, submitted a patch to configure.ac which fixes this. I am not knowledgeable enough with autoconf to review this. Could someone knowledgeable have a look at it and commit it or give me a go to commit this?
Hello, I was curious if anyone had a chance to think about this bug or if anyone had a minute to try a quick experiment.
In configure.ac, there is a block used to check if gcc can use -Wno-pointer-sign in CFLAGS. Unfortunately, the "AC_LANG(g++)" means that g++ is used for this compile test when gcc should be used, CLFLAGS is ignored, and the test always passes. For gcc4 this doesn't matter, but this breaks gcc3 when building in src/libcroco.
If anyone with gcc 3 or 4 could try a reconfigure, that would be helpful to see if this fixes other environments with gcc <4 and also does not break gcc4. Adding "AC_LANG_PUSH(C)" and "AC_LANG_POP" around the AC_COMPILE_IFELSE in configure.ac seems to fix this problem (see attached patch which is also in tracker #1702352). I've tried this patch on gcc3.3 OS 10.3.9.
After changing configure.ac, run ./autogen.sh then ./configure. For gcc<4, the final bit of configure output should not have -Wno-pointer-sign in CFLAGS.
Thanks in advance! , John
participants (1)
-
John Faith