<-- Warning: charset 'X-UNKNOWN' is not supported -->
One could also do:
printf(" -d debug: show compiled code; implies -i\n"
" -i show information about compiled pattern\n");
#if !defined NOPOSIX
printf(" -p use POSIX interface\n");
#endif
printf(" -s output store information\n"
" -t time compilation and execution\n");
On Tue, 19 Jun 2001, Philip Hazel wrote:
> On Tue, 19 Jun 2001, Fr?d?ric L. W. Meunier wrote:
>
> > Exim 3.30 doesn't build with GCC 3.0:
> >
> > gcc -c -DNOPOSIX -O pcretest.c
> > pcretest.c:474:1: directives may not be used inside a macro argument
>
> The code in question reads:
>
> printf(" -d debug: show compiled code; implies -i\n"
> " -i show information about compiled pattern\n"
> #if !defined NOPOSIX
> " -p use POSIX interface\n"
> #endif
> " -s output store information\n"
> " -t time compilation and execution\n");
>
> It looks as if gcc 3.0 has printf defined as a macro. IMHO this is
> lunacy.
>
> Try inserting
>
> #undef printf
>
> immediately before that statement, and see if it makes it work. (The C
> standard requires all standard functions to be available as functions,
> even if they are also defined as macros.)
>
> If that doesn't work, well, I suppose the thing can be rewritten so as
> to duplicate the text in the source. What an annoying restriction.
>
> There may be other places in the source where I have done this. What do
> the C style gurus on this list think? Is it an unreasonable thing to do?
>
>
--