find_path.rst 1.19 KB
Newer Older
1
2
3
find_path
---------

4
5
6
7
8
.. |FIND_XXX| replace:: find_path
.. |NAMES| replace:: NAMES name1 [name2 ...]
.. |SEARCH_XXX| replace:: file in a directory
.. |SEARCH_XXX_DESC| replace:: directory containing the named file
.. |XXX_SUBDIR| replace:: include
9

10
.. |CMAKE_PREFIX_PATH_XXX| replace::
11
   <prefix>/include/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
12
13
14
   |CMAKE_PREFIX_PATH_XXX_SUBDIR|
.. |CMAKE_XXX_PATH| replace:: CMAKE_INCLUDE_PATH
.. |CMAKE_XXX_MAC_PATH| replace:: CMAKE_FRAMEWORK_PATH
15

16
.. |SYSTEM_ENVIRONMENT_PATH_XXX| replace:: PATH and INCLUDE
17

18
.. |CMAKE_SYSTEM_PREFIX_PATH_XXX| replace::
19
   <prefix>/include/<arch> if CMAKE_LIBRARY_ARCHITECTURE is set, and
20
21
22
   |CMAKE_SYSTEM_PREFIX_PATH_XXX_SUBDIR|
.. |CMAKE_SYSTEM_XXX_PATH| replace:: CMAKE_SYSTEM_INCLUDE_PATH
.. |CMAKE_SYSTEM_XXX_MAC_PATH| replace:: CMAKE_SYSTEM_FRAMEWORK_PATH
23

24
25
.. |CMAKE_FIND_ROOT_PATH_MODE_XXX| replace::
   CMAKE_FIND_ROOT_PATH_MODE_INCLUDE
26

27
.. include:: FIND_XXX.txt
28
29
30
31
32

When searching for frameworks, if the file is specified as A/b.h, then
the framework search will look for A.framework/Headers/b.h.  If that
is found the path will be set to the path to the framework.  CMake
will convert this to the correct -F option to include the file.