From 12dcf9e4fb23101a0cb589305f65b2c123c29139 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 13 Jan 2010 13:36:03 -0500 Subject: [PATCH] Search prefix /usr before root prefix / Commit "Find locally installed software first" made /usr/local the first prefix searched to be consistent with the Filesystem Hierarchy Standard: http://www.pathname.com/fhs/ The standard also implies that the root prefix "/" should not have any package or development files. The "/bin" and "/lib" directories should have only minimal contents to boot the system. No "/include" ever exists. This commit re-orders the search path prefix list from /usr/local / /usr to /usr/local /usr / to prefer package and development files over low-level system files. See issue #10136. On Cygwin /usr/lib == /lib and /usr/bin == /bin. This change also makes search results report locations as "/usr/..." instead of "/lib/...". See issue #10122. --- Modules/Platform/UnixPaths.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/Platform/UnixPaths.cmake b/Modules/Platform/UnixPaths.cmake index ea64b781d..025ae5102 100644 --- a/Modules/Platform/UnixPaths.cmake +++ b/Modules/Platform/UnixPaths.cmake @@ -33,7 +33,7 @@ GET_FILENAME_COMPONENT(_CMAKE_INSTALL_DIR "${_CMAKE_INSTALL_DIR}" PATH) # search types. LIST(APPEND CMAKE_SYSTEM_PREFIX_PATH # Standard - /usr/local / /usr + /usr/local /usr / # CMake install location "${_CMAKE_INSTALL_DIR}"