Hi Everyone, I'm trying to build cURL, Git, Wget and several other utilities on some ancient systems. We still use early Fedora and early Ubuntu VM's to regression test. We claim to support GCC 2.95 and above. We test on early Fedora and early Ubuntu to verify the claim.
I'm catching a lot of build errors due to Gnulib on early Linux due to these definitions from Gnulib 's ctype.h. It looks like GCC disagrees with the strategy of defining __THROW to something like throw() in a C program. /* GCC can always grok prototypes. For C++ programs we add throw() to help it optimize the function calls. But this works only with gcc 2.8.x and egcs. For gcc 3.2 and up we even mark C functions as non-throwing using a function attribute since programs can use the -fexceptions options for C code as well. */ # if !defined __cplusplus && __GNUC_PREREQ (3, 3) # define __THROW __attribute__ ((__nothrow__ __LEAF)) # define __THROWNL __attribute__ ((__nothrow__)) # define __NTH(fct) __attribute__ ((__nothrow__ __LEAF)) fct # define __NTHNL(fct) __attribute__ ((__nothrow__)) fct # else # if defined __cplusplus && __GNUC_PREREQ (2,8) # define __THROW throw () # define __THROWNL throw () # define __NTH(fct) __LEAF_ATTR fct throw () # define __NTHNL(fct) fct throw () # else # define __THROW # define __THROWNL # define __NTH(fct) fct # define __NTHNL(fct) fct # endif # endif The strategy results in hundreds of these (encountered when building gettext): In file included from regex_internal.h:24, from regex.c:68: /usr/include/ctype.h:192: error: parse error before '{' token /usr/include/ctype.h:198: error: parse error before '{' token In file included from /usr/include/stdio.h:828, from ../gnulib-lib/stdio.h:43, from regex_internal.h:25, from regex.c:68: /usr/include/bits/stdio.h:113: error: parse error before '{' token /usr/include/bits/stdio.h:120: error: parse error before '{' token In file included from ../gnulib-lib/stdlib.h:36, from regex_internal.h:26, from regex.c:68: /usr/include/stdlib.h:310: error: parse error before '{' token /usr/include/stdlib.h:316: error: parse error before '{' token /usr/include/stdlib.h:322: error: parse error before '{' token /usr/include/stdlib.h:331: error: parse error before '{' token /usr/include/stdlib.h:336: error: parse error before '{' token /usr/include/stdlib.h:346: error: parse error before '{' token /usr/include/stdlib.h:352: error: parse error before '{' token /usr/include/stdlib.h:362: error: parse error before '{' token /usr/include/stdlib.h:368: error: parse error before '{' token /usr/include/stdlib.h:377: error: parse error before '{' token /usr/include/stdlib.h:382: error: parse error before '{' token /usr/include/stdlib.h:387: error: parse error before '{' token /usr/include/stdlib.h:396: error: parse error before '{' token In file included from ../gnulib-lib/wchar.h:87, from regex_internal.h:31, from regex.c:68: /usr/include/wchar.h:325: error: parse error before '{' token /usr/include/wchar.h:530: error: parse error before '{' token /usr/include/wchar.h:534: error: parse error before '{' token /usr/include/wchar.h:538: error: parse error before '{' token /usr/include/wchar.h:544: error: parse error before '{' token /usr/include/wchar.h:547: error: parse error before '{' token /usr/include/wchar.h:554: error: parse error before '{' token /usr/include/wchar.h:560: error: parse error before '{' token In file included from ../gnulib-lib/stdint.h:112, from regex_internal.h:34, from regex.c:68: /usr/include/inttypes.h:399: error: parse error before '{' token /usr/include/inttypes.h:417: error: parse error before '{' token /usr/include/inttypes.h:433: error: parse error before '{' token /usr/include/inttypes.h:452: error: parse error before '{' token It breaks both early Fedora and early Ubuntu. You can find the downloads at the URLs below. The downloads provide Fedora 1 and Ubuntu 4. * https://archive.fedoraproject.org/pub/archive/fedora/linux/core/ * http://old-releases.ubuntu.com/releases/ If you setup the VM for testing and you are using VirtualBox, then change disk storage from SATA to IDE, change USB to 1.0, and change input type to PS/2. Jeff