| Server IP : 50.21.180.56 / Your IP : 216.73.216.224 Web Server : Apache System : Linux info 3.0 #1337 SMP Tue Jan 01 00:00:00 CEST 2000 all GNU/Linux User : ws67922704 ( 67922704) PHP Version : 8.5.13 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /kunden/proc/thread-self/root/usr/share/cmake-3.31/Help/variable/ |
Upload File : |
ENV
---
Operator to read environment variables.
Use the syntax ``$ENV{VAR}`` to read environment variable ``VAR``.
To test whether an environment variable is defined, use the signature
``if(DEFINED ENV{<name>})`` of the :command:`if` command.
.. note::
Environment variable names containing special characters like parentheses
may need to be escaped. (Policy :policy:`CMP0053` must also be enabled.)
For example, to get the value of the Windows environment variable
``ProgramFiles(x86)``, use:
.. code-block:: cmake
set(ProgramFiles_x86 "$ENV{ProgramFiles\(x86\)}")
For general information on environment variables, see the
:ref:`Environment Variables <CMake Language Environment Variables>`
section in the :manual:`cmake-language(7)` manual.