__i386__ and cpp

Jeffrey A Law law@cygnus.com
Wed Feb 25 20:56:00 GMT 1998


  In message < 199802250426.UAA07399@rtl.cygnus.com >you write:
  > This occured because the -Di386 option was moved from CPP_PREDEFINES to
  > CPP_SPEC, and hence it gets defined only if the gcc driver is called.
  > It does not get defined if cccp is called directly.
Right.

  > imake assumptions about cpp are in general a problem, since the gcc C
  > preprocessor doesn't do exactly the same thing as the old unix /lib/cpp command
  > does.  Also, this assumes that we have a separate preprocessor.  Eventually
  > we would like to integrate the preprocessor with the cc1 binary, and then
  > we won't have a separate cccp program anymore.
Yup.  But the key point to remember is all these uses of imake are
already entrenched in the community.   If we break them (like we have
until now), then we look bad.

  > We could solve these problems by making the cpp program be a shell script
  > that calls `gcc -E' instead of making cpp be a link to the cccp program.
And I assume change gcc to use "cccp" so as to avoid multiple programs
called "cpp" that do different things.

You also have to be careful to get quoting rules correct -- I tried
the same thing a few years ago and ended up writing some real C code
to ensure quoting in args was handled correctly.

jeff



More information about the Gcc mailing list