mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-06 05:40:54 -06:00
For CUDAHOSTCXX the behaviour seems to have been like this since the introduction of it in commit9cf5b98d("CUDA: Prefer environment variables CUDACXX and CUDAHOSTCXX.", 2016-11-08) and is likely unintentional judging by the wording of the commit. The documentation mistake seems to be a copy-paste error from when all the environment variables were documented in commite6b77c5f("Help: Document CMake's environment variables", 2017-09-01). Describe this explicitly as it is unlike all other similar environment variables. For CUDAARCHS we got it wrong from the get-go in commitc4ae9384("CUDA: Initialize CMAKE_CUDA_ARCHITECTURES using $ENV{CUDAARCHS}", 2020-11-24). Correcting either to follow the more standard precedence behaviour will require a policy. Fixes #23081.
24 lines
751 B
ReStructuredText
24 lines
751 B
ReStructuredText
CUDAHOSTCXX
|
|
-----------
|
|
|
|
.. versionadded:: 3.8
|
|
|
|
.. include:: ENV_VAR.txt
|
|
|
|
Preferred executable for compiling host code when compiling ``CUDA``
|
|
language files. Will only be used by CMake on the first configuration to
|
|
determine ``CUDA`` host compiler, after which the value for ``CUDAHOSTCXX`` is
|
|
stored in the cache as :variable:`CMAKE_CUDA_HOST_COMPILER`. This environment
|
|
variable is preferred over :variable:`CMAKE_CUDA_HOST_COMPILER`.
|
|
|
|
This environment variable is primarily meant for use with projects that
|
|
enable ``CUDA`` as a first-class language.
|
|
|
|
.. note::
|
|
|
|
Ignored when using :ref:`Visual Studio Generators`.
|
|
|
|
.. versionadded:: 3.13
|
|
The :module:`FindCUDA`
|
|
module will use this variable to initialize its ``CUDA_HOST_COMPILER`` setting.
|