[CMake] Passing -x=cu to FindCUDA, and specifying libraries to nvcc

Irwin Zaid irwin.zaid at physics.ox.ac.uk
Fri Jan 16 13:18:18 EST 2015


> I would feel better about a flag that changes the the match string. If
> you want to cook up a patch, I'll take a look at it (I don't have much
> time to devote to this).
>
> It should be something along the lines of.
>
> 1. Add a new CUDA variable called CUDA_FILE_MATCH_REGEX that defaults to
> "\\.cu$".
> 2. Add documentation for it at the beginning along with the other things.
> 3. Replace the before mentioned if statement to use the new variable.
>
> I think this will allow you get precisely what you want, but also allow
> for somewhat arbitrary matches for anyone else who might have slightly
> different needs.

Sounds good, thanks. I think there's a need for this, and I'll probably 
do it at some point in the near future. I'll let you know when there's a PR.

Irwin


More information about the CMake mailing list