File: find_library.rst

package info (click to toggle)
cmake 3.0.2-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie-kfreebsd
  • size: 44,040 kB
  • sloc: cpp: 160,392; ansic: 149,082; yacc: 3,254; sh: 2,825; xml: 2,427; lex: 1,234; python: 449; lisp: 267; objc: 134; f90: 105; fortran: 101; perl: 99; makefile: 71; tcl: 55; asm: 28; php: 25; ruby: 22; java: 20
file content (44 lines) | stat: -rw-r--r-- 1,787 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
find_library
------------

.. |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

.. |CMAKE_PREFIX_PATH_XXX| replace::
   <prefix>/lib/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
   |CMAKE_PREFIX_PATH_XXX_SUBDIR|
.. |CMAKE_XXX_PATH| replace:: CMAKE_LIBRARY_PATH
.. |CMAKE_XXX_MAC_PATH| replace:: CMAKE_FRAMEWORK_PATH

.. |SYSTEM_ENVIRONMENT_PATH_XXX| replace:: PATH and LIB

.. |CMAKE_SYSTEM_PREFIX_PATH_XXX| replace::
   <prefix>/lib/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
   |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

.. |CMAKE_FIND_ROOT_PATH_MODE_XXX| replace::
   :variable:`CMAKE_FIND_ROOT_PATH_MODE_LIBRARY`

.. include:: FIND_XXX.txt

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.