[cfe-dev] Separate preprocess and compile: hack or feature?
Boris Kolpackov via cfe-dev
cfe-dev at lists.llvm.org
Thu May 11 02:05:43 PDT 2017
In the build system I am working on we are looking at always performing
the preprocessing and then C/C++ compilation as two separate clang/clang++
invocations. The main reason is support for distributed compilation but
see here for other reasons.
I realize that tools like ccache/distcc have been relying on this for
a while (though see the 'direct' mode in ccache and 'pump' in distcc).
However, some compilers apparently do not support this (for example,
VC; see the above link for details).
So I wonder, in the context of Clang, if this is just a hack that
happens to work "for now" or if this is a feature that is expected
to continue to work?
Also, has anyone seen/heard of any real-world issues with compiling
preprocessed source code?
More information about the cfe-dev