summaryrefslogtreecommitdiffstats
path: root/Help/envvar/CXXFLAGS.rst
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2022-10-18 17:18:12 (GMT)
committerBrad King <brad.king@kitware.com>2022-10-18 18:10:41 (GMT)
commite0075799ed97951c62f749eae671cefb62b2e694 (patch)
tree9318b6e6ae68f4c05ace515f31e6838744d1e471 /Help/envvar/CXXFLAGS.rst
parent787fc8caa8c46b7c29e05c9b367f8e85665845d4 (diff)
downloadCMake-e0075799ed97951c62f749eae671cefb62b2e694.zip
CMake-e0075799ed97951c62f749eae671cefb62b2e694.tar.gz
CMake-e0075799ed97951c62f749eae671cefb62b2e694.tar.bz2
Help: Clarify how language-specific flag environment values are used
Previous the wording could be interpreted to mean that the environment variables like `CXXFLAGS` are used exclusively to initialize the corresponding cache entries like `CMAKE_CXX_FLAGS`. State clearly that the value will be used in combination with builtin defaults. Issue: #23956
Diffstat (limited to 'Help/envvar/CXXFLAGS.rst')
-rw-r--r--Help/envvar/CXXFLAGS.rst11
1 files changed, 5 insertions, 6 deletions
diff --git a/Help/envvar/CXXFLAGS.rst b/Help/envvar/CXXFLAGS.rst
index 460a347..f67431f 100644
--- a/Help/envvar/CXXFLAGS.rst
+++ b/Help/envvar/CXXFLAGS.rst
@@ -3,11 +3,10 @@ CXXFLAGS
.. include:: ENV_VAR.txt
-Default compilation flags to be used when compiling ``CXX`` (C++) files. Will
-only be used by CMake on the first configuration to determine ``CXX`` default
-compilation flags, after which the value for ``CXXFLAGS`` is stored in the cache
-as :variable:`CMAKE_CXX_FLAGS <CMAKE_<LANG>_FLAGS>`. For any configuration run (
-including the first), the environment variable will be ignored if
-the :variable:`CMAKE_CXX_FLAGS <CMAKE_<LANG>_FLAGS>` variable is defined.
+Add default compilation flags to be used when compiling ``CXX`` (C++) files.
+
+.. |CMAKE_LANG_FLAGS| replace:: :variable:`CMAKE_CXX_FLAGS <CMAKE_<LANG>_FLAGS>`
+.. |LANG| replace:: ``CXX``
+.. include:: LANG_FLAGS.txt
See also :variable:`CMAKE_CXX_FLAGS_INIT <CMAKE_<LANG>_FLAGS_INIT>`.