Re: [CMake] CUDA language support with host compiler flags

2019-02-28 Thread Robert Maynard via CMake
e: 2019. február 27., szerda 15:00 > Címzett: Nagy-Egri MĂĄtĂŠ Ferenc > Másolatot kap: CMake MailingList > Tárgy: Re: [CMake] CUDA language support with host compiler flags > > > > You need to guard the flags with `$` the > > evaluation on a given compiler id is done

Re: [CMake] CUDA language support with host compiler flags

2019-02-28 Thread Máté Ferenc Nagy-Egri via CMake
/MathiasMagnus/0edacac888a758fe233cb69f3e291d62 Cheers, Máté Feladó: Robert Maynard Elküldve: 2019. február 27., szerda 15:00 Címzett: Nagy-Egri MĂĄtĂŠ Ferenc Másolatot kap: CMake MailingList Tárgy: Re: [CMake] CUDA language support with host compiler flags You need to guard the flags with `$` the

Re: [CMake] CUDA language support with host compiler flags

2019-02-27 Thread Robert Maynard via CMake
You need to guard the flags with `$` the evaluation on a given compiler id is done for all sources of a target, and not on each target source file. So you will need something like: set(cxx_flags "$<$,$>:-Wall -Wextra -pedantic> $<$:/W4") target_compi

[CMake] CUDA language support with host compiler flags

2019-02-22 Thread Máté Ferenc Nagy-Egri via CMake
Hi All! I am trying to compile CUDA code with controlling both host and device compiler flags. Currently my CMakeLists.txt looks like: ``` cmake_minimum_required(VERSION 3.8) # CUDA language support project(CUDA_test LANGUAGES CXX CUDA) if (MSVC)   string(REGEX REPLACE "/W[0-9]" "" CMAKE_CX

[CMake] CUDA language support with host compiler flags

2019-02-21 Thread Máté Ferenc Nagy-Egri via CMake
Hi All! I am trying to compile CUDA code with controlling both host and device compiler flags. Currently my CMakeLists.txt looks like: ``` cmake_minimum_required(VERSION 3.8) # CUDA language support project(CUDA_test LANGUAGES CXX CUDA) if (MSVC)   string(REGEX REPLACE "/W[0-9]" "" CMAKE_CXX_FLA