configuration should check that the compiler will work with nvcc - Redmine #1616
We’ve had a couple of gmx-users posts complain of a build-time error
from nvcc when someone uses a compiler that their CUDA version does not
support. One of them thought that it meant that we don’t support icc 14,
for example.
We can check for this with CMake at configure time, simply by compiling
a test program. We do this for lots of other functionality, so I think
we should do it for CUDA also.
I would suggest that a failure is fatal (and descriptive), since the
decision of which compiler and which CUDA version to use needs user
involvement. Also suggest release-5-0 branch. Should we suggest the
work-around of hacking off the check in the CUDA headers?
*(from redmine: issue id 1616, created on 2014-10-04 by mark.j.abraham, closed on 2018-01-05)*
* Relations:
* relates #2583
* Changesets:
* Revision 5e9bcbcf84f7c4e909bfa4ac59a00e208f74eccf by Erik Lindahl on 2018-01-05T15:58:23Z:
```
Test that nvcc/host compiler combo works
Compile a trivial CUDA program during CMake time
to catch both unsupported nvcc/host compiler
version combinations and other unknown errors.
Fixes #1616.
Change-Id: I3cc55e4d0db9d6eb01e8a7cd8916cc7a7a1e21fd
```
* Revision 029e1e95a9f7036052d87dffeab240d4616a7085 by Mark Abraham on 2019-01-28T16:49:52Z:
```
Stop trying to check nvcc on Windows
The execute_process() call used in this check is not constructed to
work on Windows, so we should not run it there.
Refs #1616
Change-Id: I2103b78203f71d3f68b54898dd03c8fe0eb0fa4c
```
issue