On Tue, Nov 17, 2015 at 6:50 AM, Brad King <brad.k...@kitware.com> wrote:

> On 11/16/2015 03:14 PM, Levi Morrison wrote:
> > It seems my attachments are getting scrubbed or something?
>
> It was just that one message that was missing one.  This one worked.
>
> >> How did you test these?  For full testing we need the CMake test
> >> suite to pass with the Intel compilers.  In particular, tests with
> >> 'CompileFeatures' in their name cover this functionality.
> >
> > I was able to build and use (or not use as appropriately) C++11 and
> > C++14 for a given project I already have.
>
> Good start.
>
> > What is the proper way to do run the test suite for a given compiler?
>
> One can run the entire test suite like this:
>
>  export CC=icc CXX=icpc
>  mkdir CMake-intel-tests && cd CMake-intel-tests
>  cmake ../CMake -DCMake_TEST_EXTERNAL_CMAKE="/path/to/main/CMake-build/bin"
>  make
>

:D Funnily enough

>  ctest
>
> Or on the last step run just specific tests:
>
>  ctest -R CompileFeatures -V
>
> I just tried the patch locally.  While these tests do pass, the compile
> features are not actually recorded.  What is missing is a file called
>
>  Modules/Compiler/Intel-CXX-FeatureTests.cmake
>
> that records how to use the preprocessor to test for the version of the
> compiler that adds each feature.  See these for some examples:
>
>  Modules/Compiler/GNU-CXX-FeatureTests.cmake
>  Modules/Compiler/MSVC-CXX-FeatureTests.cmake
>
> Then the Tests/CompileFeatures/CMakeLists.txt file also needs to be
> updated to enable testing for versions of the Intel compiler that are
> expected to work.
>
> Building the feature table may not be a trivial task.  It is one of
> the reasons no one has added support yet.  If you have access to
> versions 12, 13, 14, 15, then running the test suite with each of
> those will help verify the table correctness.
>
> -Brad
>
>
I have updated Modules/Compiler/Intel-CXX-FeatureTests.cmake. It took a
while :D

I'm not sure how to edit Tests/CompileFeatures/CMakeLists.txt, though. I
don't even know what half of this file is trying to accomplish. It seems
like it is pure duplication of work; these checks are saying
EXPECT_C_STATIC_ASSERT=1 if some compiler conditions are true but I already
encoded that information in Intel-CXX-FeatureTests.cmake, didn't I?

In any case, it seems I still need to update something because after
editing that file I am unable to use `target_compile_features(sometarget
PRIVATE cxx_nullptr)`, etc. I get the message:

CMake Error at CMakeLists.txt:7 (target_compile_features):

  target_compile_features no known features for CXX compiler

  "Intel"

  version 15.0.3.20150407.
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to