2013-10-15 19:17:36 +04:00
|
|
|
find_library
|
|
|
|
------------
|
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. |FIND_XXX| replace:: find_library
|
|
|
|
.. |NAMES| replace:: NAMES name1 [name2 ...] [NAMES_PER_DIR]
|
|
|
|
.. |SEARCH_XXX| replace:: library
|
|
|
|
.. |SEARCH_XXX_DESC| replace:: library
|
|
|
|
.. |XXX_SUBDIR| replace:: lib
|
2013-10-15 19:17:36 +04:00
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. |CMAKE_PREFIX_PATH_XXX| replace::
|
2013-10-15 19:17:36 +04:00
|
|
|
<prefix>/lib/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
|
2013-10-01 20:37:02 +04:00
|
|
|
|CMAKE_PREFIX_PATH_XXX_SUBDIR|
|
|
|
|
.. |CMAKE_XXX_PATH| replace:: CMAKE_LIBRARY_PATH
|
|
|
|
.. |CMAKE_XXX_MAC_PATH| replace:: CMAKE_FRAMEWORK_PATH
|
2013-10-15 19:17:36 +04:00
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. |SYSTEM_ENVIRONMENT_PATH_XXX| replace:: PATH and LIB
|
2013-10-15 19:17:36 +04:00
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. |CMAKE_SYSTEM_PREFIX_PATH_XXX| replace::
|
2013-10-15 19:17:36 +04:00
|
|
|
<prefix>/lib/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
|
2013-10-01 20:37:02 +04:00
|
|
|
|CMAKE_SYSTEM_PREFIX_PATH_XXX_SUBDIR|
|
|
|
|
.. |CMAKE_SYSTEM_XXX_PATH| replace:: CMAKE_SYSTEM_LIBRARY_PATH
|
|
|
|
.. |CMAKE_SYSTEM_XXX_MAC_PATH| replace:: CMAKE_SYSTEM_FRAMEWORK_PATH
|
2013-10-15 19:17:36 +04:00
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. |CMAKE_FIND_ROOT_PATH_MODE_XXX| replace::
|
2013-11-26 22:58:07 +04:00
|
|
|
:variable:`CMAKE_FIND_ROOT_PATH_MODE_LIBRARY`
|
2013-10-15 19:17:36 +04:00
|
|
|
|
2013-10-01 20:37:02 +04:00
|
|
|
.. include:: FIND_XXX.txt
|
2013-10-15 19:17:36 +04:00
|
|
|
|
|
|
|
When more than one value is given to the NAMES option this command by
|
|
|
|
default will consider one name at a time and search every directory
|
|
|
|
for it. The NAMES_PER_DIR option tells this command to consider one
|
|
|
|
directory at a time and search for all names in it.
|
|
|
|
|
|
|
|
If the library found is a framework, then VAR will be set to the full
|
|
|
|
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 global property FIND_LIBRARY_USE_LIB64_PATHS is set all search
|
|
|
|
paths will be tested as normal, with "64/" appended, and with all
|
|
|
|
matches of "lib/" replaced with "lib64/". This property is
|
|
|
|
automatically set for the platforms that are known to need it if at
|
|
|
|
least one of the languages supported by the PROJECT command is
|
|
|
|
enabled.
|