[cfe-dev] how to precompile headers
Jean-Daniel Dupas
devlists at shadowlab.org
Tue May 11 14:57:02 PDT 2010
Le 11 mai 2010 à 22:51, Jochen Wilhelmy a écrit :
> Hi!
>
> is it possible to precompile some headers using clang
> and then inject it when I compile some code?
> (Basically the usual precompiled headers feature)
>
Yes. IIRC, you can use the -x flag to compile the header
clang -x c-header YourHeader.h -o YourHeader.gch
and the -include flag to include it.
clang -include YourHeader.gch ....
-- Jean-Daniel
More information about the cfe-dev
mailing list