diff options
author | Brad King <brad.king@kitware.com> | 2021-06-08 12:04:11 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-06-08 12:04:16 (GMT) |
commit | d1517a4ef953510a65da6be29b54be2fc59409e2 (patch) | |
tree | 390cb69534420e93313a3fc763bdd39df4b87cb3 /Help/variable | |
parent | 105e108836403379cda176ec0a16fafc0a06464a (diff) | |
parent | 8f68bcad8fafddc82b73b69f21e122ece8603a8f (diff) | |
download | CMake-d1517a4ef953510a65da6be29b54be2fc59409e2.zip CMake-d1517a4ef953510a65da6be29b54be2fc59409e2.tar.gz CMake-d1517a4ef953510a65da6be29b54be2fc59409e2.tar.bz2 |
Merge topic 'compile-options-order'
8f68bcad8f Tests: Add cases verifying flag ordering rules
ccc83ce162 Help: Document order of flags from CMAKE_<LANG>_FLAGS and COMPILE_OPTIONS
df79fe055b Help: Remove incorrect "versionadded" for CMAKE_<LANG>_FLAGS_<CONFIG>
c48d2d8480 VS: Place per-source preprocessor definitions after target-wide ones
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6187
Diffstat (limited to 'Help/variable')
-rw-r--r-- | Help/variable/CMAKE_LANG_FLAGS.rst | 5 | ||||
-rw-r--r-- | Help/variable/CMAKE_LANG_FLAGS_CONFIG.rst | 7 |
2 files changed, 10 insertions, 2 deletions
diff --git a/Help/variable/CMAKE_LANG_FLAGS.rst b/Help/variable/CMAKE_LANG_FLAGS.rst index 11864f8..2784397 100644 --- a/Help/variable/CMAKE_LANG_FLAGS.rst +++ b/Help/variable/CMAKE_LANG_FLAGS.rst @@ -18,3 +18,8 @@ This is initialized for each language from environment variables: This value is a command-line string fragment. Therefore, multiple options should be separated by spaces, and options with spaces should be quoted. + +The flags in this variable will be passed to the compiler before those +in the per-configuration :variable:`CMAKE_<LANG>_FLAGS_<CONFIG>` variant, +and before flags added by the :command:`add_compile_options` or +:command:`target_compile_options` commands. diff --git a/Help/variable/CMAKE_LANG_FLAGS_CONFIG.rst b/Help/variable/CMAKE_LANG_FLAGS_CONFIG.rst index 628b62b..f0900fd 100644 --- a/Help/variable/CMAKE_LANG_FLAGS_CONFIG.rst +++ b/Help/variable/CMAKE_LANG_FLAGS_CONFIG.rst @@ -1,6 +1,9 @@ CMAKE_<LANG>_FLAGS_<CONFIG> --------------------------- -.. versionadded:: 3.11 - Flags for language ``<LANG>`` when building for the ``<CONFIG>`` configuration. + +The flags in this variable will be passed to the compiler after those +in the :variable:`CMAKE_<LANG>_FLAGS` variable, but before flags added +by the :command:`add_compile_options` or :command:`target_compile_options` +commands. |