Hello

sometime ago I sent this email concerning the behaviour of the SYSTEM in the 
include_directories.
I would appreciate if someone from cmake team could look at it, as we consider 
this a bug in cmake, and indeed properly passing -isystem to the compiler is 
essential, specially in CUDA when system library flood the compilation output 
with warning.

Thanks. Carlos

________________________________
Von: Osuna Escamilla Carlos
Gesendet: Sonntag, 14. Februar 2016 19:33
An: [email protected]
Betreff: isystem include of system library header with CUDA

Hi everybody

with cmake I have always used the SYSTEM keyword for the include_directories to 
include system libraries:

include_directories( SYSTEM ${Boost_INCLUDE_DIRS} )

in order to pass system include directories with compiler with -isystem.
The problem I have is that this does not seem to work with CUDA.

In FindCUDA.cmake, it seems that -I is hardcoded

  if(CUDA_NVCC_INCLUDE_DIRECTORIES)
    foreach(dir ${CUDA_NVCC_INCLUDE_DIRECTORIES})
      list(APPEND CUDA_NVCC_INCLUDE_ARGS -I${dir})
    endforeach()
  endif()

So the question is am I right? Or am I assuming something wrong?
If yes, it would be extremely useful if we could use the same mechanism to pass 
-isystem to nvcc, to avoid all the warnings from system libraries.

Thanks, Carlos
-- 

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

Reply via email to