[PATCH] Check the consistency of the C and C++ compilers picked-up by cmake

Reid Kleckner rnk at google.com
Fri Jun 14 05:53:39 PDT 2013


On Thu, Jun 13, 2013 at 5:24 PM, Arnaud Allard de Grandmaison <
arnaud.adegm at gmail.com> wrote:

> On Thu, Jun 13, 2013 at 10:58 PM, Reid Kleckner <rnk at google.com> wrote:
>
>> The only usage of CMAKE_C(XX)_COMPILER_ID is for -fcolor-diagnostics.
>>  Why not use the feature testing macro add_flag_if_supported() used
>> elsewhere in the file?  I actually don't like those kinds of compiler tests
>> because they make configuration slow, but that's the dominant style for all
>> the other flag checking.
>>
>
> There are 2 things there :
>  - using the add_flag_if_supported() for the colored diagnostics (with
> Ninja only). I agree this would be a more idiomatic approach, and I will
> update HandleLLVMOptions.cmake accordingly.
>  - checking the consistency of the C and C++ toolchains. A side effect
> would have been to catch the previous item, but this check is way broader
> than color outputs. The point here is to catch suspicious setups. Can we
> consider mixed toolchains as suspicious ?
>

Maybe.  I can't really form a good argument either way.  If someone else
seconds it, then sgtm.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130614/a608767e/attachment.html>


More information about the llvm-commits mailing list