On Mac OS X 10.0.4, the core system is Darwin 1.3.7, and GCC is this
version:

        bash-2.05$ cc -v
        Reading specs from /usr/libexec/gcc/darwin/ppc/2.95.2/specs
        Apple Computer, Inc. version gcc-926, based on gcc version 2.95.2 19991024 
(release)

I ran into a problem compiling wget-1.7:

        cc -I. -I.    -DHAVE_CONFIG_H -DSYSTEM_WGETRC=\"/usr/local/etc/wgetrc\" 
-DLOCALEDIR=\"/usr/local/share/locale\" -g -O2 -c html-parse.c
        html-parse.c: In function `advance_declaration':
        html-parse.c:449: character constant too long
        html-parse.c:449: parse error before character constant
        html-parse.c:449: stray '\' in program
        html-parse.c:454: character constant too long
        html-parse.c:461: character constant too long
        html-parse.c:472: character constant too long
        html-parse.c:481: character constant too long
        html-parse.c:481: character constant too long
        html-parse.c:481: stray '\' in program
        html-parse.c:773: Unterminated string constant
        make[1]: *** [html-parse.o] Error 1
        make: *** [src] Error 2

The real problem is with line 435 of html-parse.c:

        assert (ch == '\'' || ch == '"');

For some reason, Apple's GCC does not like the '"' in its assert().
There are two different ways to fix this:

        1) change '"' to '\"', which is also legal ANSI C.

        2) CPPFLAGS="-traditional-cpp" ./configure

I haven't gotten an answer from Apple in any of their forums on why
assert() breaks so badly.  Comments and suggestions are welcome (please
CC me any messages, as I'm not subscribed to any Wget mailing list).
Thanks in advance.


-- 
Eugene Lee
[EMAIL PROTECTED]

Reply via email to