[ITK-users] [ITK] ITK_COMPILED_CXX_VERSION always set to 1997 on macOS

Olivier Commowick Olivier.Commowick at inria.fr
Thu Feb 2 04:09:20 EST 2017


Hi,

Ok now I get it. I was on the release branch and your modification seems to be only in the master branch yet. With it included, I have the same behaviour as yours.

Thanks
Olivier

> On 1 Feb 2017, at 21:48, Lowekamp, Bradley (NIH/NLM/LHC) [C] <blowekamp at mail.nih.gov> wrote:
> 
> Hi,
> 
> I am running Xcode 8.2.1 OS 10.11, and cmake 3.4.3. I was not able to reproduce your problem.
> For a clean build directory I ran:
>  cmake -DCMAKE_CXX_STANDARD=11 ~/src/ITK && grep  ITK_COMPILED_CXX Modules/Core/Common/itkConfigure.h
> 
> I got the following:
>  #define ITK_COMPILED_CXX_STANDARD_VERSION 201103L
>  #if ITK_COMPILED_CXX_STANDARD_VERSION > __cplusplus
> 
> There did appear to be a problem with the preprocessor variable used in the version check which I addressed here:
> http://review.source.kitware.com/#/c/22021/
> 
> Perhaps you did not start with a clean build directory?
> 
> Brad
> 
>> On Jan 31, 2017, at 5:02 AM, Olivier Commowick <Olivier.Commowick at inria.fr> wrote:
>> 
>> Hello
>> 
>> Thanks for your answer. I am running into this with Xcode 8.2.1, on a macOS 10.12, cmake version 3.6.2, and it happens already when compiling ITK itself.
>> 
>> I did not put the flag you mentioned. I could try but it seems to me that the VXL part of ITK has the same kind of test and it works. I mean by this that there is a VXL_COMPILED_CXX_STANDARD_VERSION set up in the file Modules/ThirdParty/VNL/src/vxl/config/cmake/config/VXLIntrospectionConfig.cmake . And this one is automatically set to 201103L without needing the flags you mentioned. May be there is something in this cmake file that should be ported back to the ITK equivalent (that’s just a thought of course).
>> 
>> Thanks
>> Olivier
>> 
>>> On 23 Jan 2017, at 15:25, Lowekamp, Bradley (NIH/NLM/LHC) [C] <blowekamp at mail.nih.gov> wrote:
>>> 
>>> Hello,
>>> 
>>> What Xcode version are you using? Can you produce a simple CMake command line configuration to reproduce the problem?
>>> 
>>> If you set "CMAKE_CXX_FLAGS=-std=c++11”, does the same problem occur?
>>> 
>>> Thanks!
>>> Brad
>>> 
>>>> On Jan 23, 2017, at 9:11 AM, Olivier Commowick <Olivier.Commowick at inria.fr> wrote:
>>>> 
>>>> Hello,
>>>> 
>>>> While debugging something else, I realised that the ITK_COMPILED_CXX_VERSION variable in CMake is always set to 199711L on my macOS 10.12. It sounds weird to me since I am always compiling ITK by enforcing to use CMAKE_CXX_STANDARD to 11.
>>>> 
>>>> It appears to me that Modules/Core/Common/CMakeLists.txt does this test and probably does not account for the fact that cmake uses the 2011 standard or something else. Would someone have any idea of how to correct this or if this is important or not ?
>>>> 
>>>> Best
>>>> Olivier
>>>> 
>>>> ---
>>>> 
>>>> Olivier Commowick, Ph.D.
>>>> Research Scientist
>>>> INRIA Rennes - Bretagne Atlantique, VISAGES Team
>>>> Campus de Beaulieu
>>>> 35042 Rennes
>>>> FRANCE
>>>> 
>>>> Phone: +33 2 99 84 25 92
>>>> Email: Olivier.Commowick at inria.fr
>>>> Web: http://olivier.commowick.org/
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> _____________________________________
>>>> Powered by www.kitware.com
>>>> 
>>>> Visit other Kitware open-source projects at
>>>> http://www.kitware.com/opensource/opensource.html
>>>> 
>>>> Kitware offers ITK Training Courses, for more information visit:
>>>> http://www.kitware.com/products/protraining.php
>>>> 
>>>> Please keep messages on-topic and check the ITK FAQ at:
>>>> http://www.itk.org/Wiki/ITK_FAQ
>>>> 
>>>> Follow this link to subscribe/unsubscribe:
>>>> http://public.kitware.com/mailman/listinfo/insight-users
>>>> _______________________________________________
>>>> Community mailing list
>>>> Community at itk.org
>>>> http://public.kitware.com/mailman/listinfo/community
>>> 
>> 
>> 
>> ---
>> 
>> Olivier Commowick, Ph.D.
>> Research Scientist
>> INRIA Rennes - Bretagne Atlantique, VISAGES Team
>> Campus de Beaulieu
>> 35042 Rennes
>> FRANCE
>> 
>> Phone: +33 2 99 84 25 92
>> Email: Olivier.Commowick at inria.fr
>> Web: http://olivier.commowick.org/
>> 
>> 
>> 
>> 
>> 
> 




More information about the Insight-users mailing list