[CMake] Compiler flags for Obj-C++ files only

Bill Hoffman bill.hoffman at kitware.com
Wed May 21 15:52:50 EDT 2008


E. Wing wrote:
> I believe the answer is no. I think Sean McBride and I brought this up
> before and agree with you that we need a case like this. The bug is
> filed here:
> http://public.kitware.com/Bug/view.php?id=4756
> 
> Please feel free to add additional information (or submit a patch :))
> 
> 
> On 5/21/08, Allan Odgaard <jovxhr102 at sneakemail.com> wrote:
>> I need to set a compiler flag for Obj-C++ files (-fobjc-call-cxx-
>> cdtors).
>>
>> Setting it for C++ will give a warning from gcc when the source file
>> type is C++ (instead of Obj-C++).
>>
>> Is there any way to set flags for only Obj-C++ files?
>>

You could use a source file property compile flag as a work around.

-Bill


More information about the CMake mailing list