summaryrefslogtreecommitdiffstats
path: root/Help/command/find_library.rst
diff options
context:
space:
mode:
authorChristian Schmidbauer <ch.schmidbauer@gmail.com>2017-02-25 18:47:49 (GMT)
committerBrad King <brad.king@kitware.com>2017-03-01 14:49:42 (GMT)
commit503f25d490e56dfc1d3dc894e1fc1bd3e7e89e81 (patch)
treec5e35271ce09ec7fba4fcef5d176ed17676470e9 /Help/command/find_library.rst
parent78104bd7bca4bd9b4b7a5c17622838a33843138e (diff)
downloadCMake-503f25d490e56dfc1d3dc894e1fc1bd3e7e89e81.zip
CMake-503f25d490e56dfc1d3dc894e1fc1bd3e7e89e81.tar.gz
CMake-503f25d490e56dfc1d3dc894e1fc1bd3e7e89e81.tar.bz2
find_library: Allow custom lib suffix be used as find path
Add a new `CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX` variable to allow use of a custom suffix on `lib` directory names. This is a more general option than that added by commit v3.7.0-rc1~504^2 (Teach find_library and find_package to search lib32 paths, 2016-06-10). It allows the find path to be more deterministic on custom setups. See discussion in #10287 and #15994.
Diffstat (limited to 'Help/command/find_library.rst')
-rw-r--r--Help/command/find_library.rst7
1 files changed, 7 insertions, 0 deletions
diff --git a/Help/command/find_library.rst b/Help/command/find_library.rst
index 1eb50f7..e912040 100644
--- a/Help/command/find_library.rst
+++ b/Help/command/find_library.rst
@@ -49,6 +49,13 @@ path to the framework ``<fullPath>/A.framework``. When a full path to a
framework is used as a library, CMake will use a ``-framework A``, and a
``-F<fullPath>`` to link the framework to the target.
+If the :variable:`CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX` variable is set all
+search paths will be tested as normal, with the suffix appended, and with
+all matches of ``lib/`` replaced with
+``lib${CMAKE_FIND_LIBRARY_CUSTOM_LIB_SUFFIX}/``. This variable overrides
+the :prop_gbl:`FIND_LIBRARY_USE_LIB32_PATHS`
+and :prop_gbl:`FIND_LIBRARY_USE_LIB64_PATHS` global properties.
+
If the :prop_gbl:`FIND_LIBRARY_USE_LIB32_PATHS` global property is set
all search paths will be tested as normal, with ``32/`` appended, and
with all matches of ``lib/`` replaced with ``lib32/``. This property is