Honor CMAKE_*_LINKER_FLAGS[_<CONFIG>]_INIT set in toolchain files

Document these variables.

Change our convention for setting these variables from:

    set(CMAKE_EXE_LINKER_FLAGS_INIT "...")

to

    string(APPEND CMAKE_EXE_LINKER_FLAGS_INIT " ...")

so that any value previously set by a toolchain file will be used.
This commit is contained in:
Brad King
2016-07-13 15:06:23 -04:00
parent 37d15c399e
commit 8a98cf6432
20 changed files with 195 additions and 21 deletions

View File

@@ -0,0 +1,10 @@
CMAKE_EXE_LINKER_FLAGS_<CONFIG>_INIT
------------------------------------
Value used to initialize the :variable:`CMAKE_EXE_LINKER_FLAGS_<CONFIG>`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also :variable:`CMAKE_EXE_LINKER_FLAGS_INIT`.

View File

@@ -0,0 +1,11 @@
CMAKE_EXE_LINKER_FLAGS_INIT
---------------------------
Value used to initialize the :variable:`CMAKE_EXE_LINKER_FLAGS`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also the configuration-specific variable
:variable:`CMAKE_EXE_LINKER_FLAGS_<CONFIG>_INIT`.

View File

@@ -0,0 +1,10 @@
CMAKE_MODULE_LINKER_FLAGS_<CONFIG>_INIT
---------------------------------------
Value used to initialize the :variable:`CMAKE_MODULE_LINKER_FLAGS_<CONFIG>`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also :variable:`CMAKE_MODULE_LINKER_FLAGS_INIT`.

View File

@@ -0,0 +1,11 @@
CMAKE_MODULE_LINKER_FLAGS_INIT
------------------------------
Value used to initialize the :variable:`CMAKE_MODULE_LINKER_FLAGS`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also the configuration-specific variable
:variable:`CMAKE_MODULE_LINKER_FLAGS_<CONFIG>_INIT`.

View File

@@ -0,0 +1,10 @@
CMAKE_SHARED_LINKER_FLAGS_<CONFIG>_INIT
---------------------------------------
Value used to initialize the :variable:`CMAKE_SHARED_LINKER_FLAGS_<CONFIG>`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also :variable:`CMAKE_SHARED_LINKER_FLAGS_INIT`.

View File

@@ -0,0 +1,11 @@
CMAKE_SHARED_LINKER_FLAGS_INIT
------------------------------
Value used to initialize the :variable:`CMAKE_SHARED_LINKER_FLAGS`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also the configuration-specific variable
:variable:`CMAKE_SHARED_LINKER_FLAGS_<CONFIG>_INIT`.

View File

@@ -0,0 +1,10 @@
CMAKE_STATIC_LINKER_FLAGS_<CONFIG>_INIT
---------------------------------------
Value used to initialize the :variable:`CMAKE_STATIC_LINKER_FLAGS_<CONFIG>`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also :variable:`CMAKE_STATIC_LINKER_FLAGS_INIT`.

View File

@@ -0,0 +1,11 @@
CMAKE_STATIC_LINKER_FLAGS_INIT
------------------------------
Value used to initialize the :variable:`CMAKE_STATIC_LINKER_FLAGS`
cache entry the first time a build tree is configured.
This variable is meant to be set by a :variable:`toolchain file
<CMAKE_TOOLCHAIN_FILE>`. CMake may prepend or append content to
the value based on the environment and target platform.
See also the configuration-specific variable
:variable:`CMAKE_STATIC_LINKER_FLAGS_<CONFIG>_INIT`.