diff options
Diffstat (limited to 'Help')
-rw-r--r-- | Help/manual/cmake-variables.7.rst | 11 | ||||
-rw-r--r-- | Help/variable/CACHE.rst | 5 | ||||
-rw-r--r-- | Help/variable/ENV.rst | 8 |
3 files changed, 18 insertions, 6 deletions
diff --git a/Help/manual/cmake-variables.7.rst b/Help/manual/cmake-variables.7.rst index efb217d..7a7f0b8 100644 --- a/Help/manual/cmake-variables.7.rst +++ b/Help/manual/cmake-variables.7.rst @@ -241,7 +241,6 @@ Variables that Describe the System /variable/ANDROID /variable/APPLE /variable/BORLAND - /variable/CACHE /variable/CMAKE_CL_64 /variable/CMAKE_COMPILER_2005 /variable/CMAKE_HOST_APPLE @@ -260,7 +259,6 @@ Variables that Describe the System /variable/CMAKE_SYSTEM_PROCESSOR /variable/CMAKE_SYSTEM_VERSION /variable/CYGWIN - /variable/ENV /variable/GHS-MULTI /variable/MINGW /variable/MSVC @@ -599,3 +597,12 @@ Variables for CPack /variable/CPACK_PACKAGING_INSTALL_PREFIX /variable/CPACK_SET_DESTDIR /variable/CPACK_WARN_ON_ABSOLUTE_INSTALL_DESTINATION + +Variable Expansion Operators +============================ + +.. toctree:: + :maxdepth: 1 + + /variable/CACHE + /variable/ENV diff --git a/Help/variable/CACHE.rst b/Help/variable/CACHE.rst index 230739a..2cef27e 100644 --- a/Help/variable/CACHE.rst +++ b/Help/variable/CACHE.rst @@ -1,7 +1,7 @@ CACHE ----- -Read cache variables. +Operator to read cache variables. Use the syntax ``$CACHE{VAR}`` to read cache entry ``VAR``. See the :ref:`cmake-language(7) variables <CMake Language Variables>` @@ -14,4 +14,5 @@ found CMake will search for a cache entry with that name. The ``$CACHE{VAR}`` syntax can be used to do direct cache lookup and ignore any existing normal variable. -See the :command:`set` command to see how to write cache variables. +See the :command:`set` and :command:`unset` commands to see how to +write or remove cache variables. diff --git a/Help/variable/ENV.rst b/Help/variable/ENV.rst index 98677dd..2b43934 100644 --- a/Help/variable/ENV.rst +++ b/Help/variable/ENV.rst @@ -1,8 +1,12 @@ ENV --- -Read environment variables. +Operator to read environment variables. Use the syntax ``$ENV{VAR}`` to read environment variable ``VAR``. -See the :command:`set` command to see how to write environment variables. +To test whether an environment variable is defined, use the signature +``if(DEFINED ENV{<name>})`` of the :command:`if` command. + +See the :command:`set` and :command:`unset` commands to see how to +write or remove environment variables. |