On 06/21/2017 09:08 AM, Hancox, James wrote: > it almost seems like -Xcompiler flags are being deliberately stripped out.)
Unfortunately we have to strip them out to work around a bug in CUDA's VS integration. The -Xcompiler options are parsed for inclusion in AdditionalCompilerOptions in the .vcxproj file by flag map entries here: https://gitlab.kitware.com/cmake/cmake/blob/v3.9.0-rc3/Source/cmVS10CudaFlagTable.h#L3-6 Then a subset of the options that have dedicated elements defined by the CUDA VS integration are extracted by flag map entries here: https://gitlab.kitware.com/cmake/cmake/blob/v3.9.0-rc3/Source/cmVS10CudaHostFlagTable.h Ideally we should then leave the rest in AdditionalCompilerOptions, but CUDA's VS integration puts them in the wrong place and breaks builds. Therefore we have to drop them: https://gitlab.kitware.com/cmake/cmake/blob/v3.9.0-rc3/Source/cmVisualStudio10TargetGenerator.cxx#L2508-2510 We've reported this to NVIDIA but can't take the workaround out until a version of CUDA comes out that fixes it. -Brad -- 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