Hi, I was unable to build lang/gawk on AIX because of these messages..."floatcomp.c", line 83.1: 1506-191 (E) The character # is not a valid C source character.
"floatcomp.c", line 83.2: 1506-276 (S) Syntax error: possible missing ')'?"floatcomp.c", line 84.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 86.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 87.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 87.2: 1506-277 (S) Syntax error: possible missing ';' or ','?
"floatcomp.c", line 86.2: 1506-045 (S) Undeclared identifier endif."floatcomp.c", line 97.1: 1506-191 (E) The character # is not a valid C source character.
"floatcomp.c", line 97.2: 1506-276 (S) Syntax error: possible missing ')'?"floatcomp.c", line 98.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 100.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 101.1: 1506-191 (E) The character # is not a valid C source character. "floatcomp.c", line 101.2: 1506-277 (S) Syntax error: possible missing ';' or ','?
"floatcomp.c", line 100.2: 1506-045 (S) Undeclared identifier endif. *** Error code 1The following patch appears to fix it. But it may not be needed for other platforms/compilers. Actually, doesn't `#if 0' effectively comment this out anyway?
Is there a way to make a platform-specific pkgsrc patch? Louis --- floatcomp.c.orig 2009-02-23 15:38:07.000000000 -0500 +++ floatcomp.c 2009-02-23 15:40:24.000000000 -0500 @@ -79,13 +79,7 @@ AWKNUM Floor(AWKNUM n) { - return floor(n -#if 0 -#ifdef _CRAY - * (1.0 + DBL_EPSILON) -#endif -#endif - ); + return floor(n); } /* Ceil --- do ceil(), also for Cray */ @@ -93,13 +87,7 @@ AWKNUM Ceil(AWKNUM n) { - return ceil(n -#if 0 -#ifdef _CRAY - * (1.0 + DBL_EPSILON) -#endif -#endif - ); + return ceil(n); } #ifdef HAVE_UINTMAX_T
Attachment:
smime.p7s
Description: S/MIME Cryptographic Signature