nixpkgs/pkgs/development/tools/build-managers/cmake/search-path.patch
bbenoist ebc424c3ab cmake: Update to 2.8.11.2
The changelog is available at:
http://www.cmake.org/files/v2.8/CMakeChangeLog-2.8.11

I had to create a new patch from scratch, that's why it contains a lot
of differences. CMake developers has rewritten the files
(Modules/Platform/Linux.cmake and Modules/Platform/UnixPaths.cmake) to
comply to their coding style requirements and a lot of elements has
switched from upper to lower case.

Also, the previous patch partially consisted of commenting some
instructions mixed with line removals whereas mine is directlty
removing them in order to avoid useless evaluations and parsing in
resulting files.
2013-07-16 10:07:09 +02:00

94 lines
2.9 KiB
Diff

diff -ru -x '*~' cmake-2.8.11.2-orig/Modules/Platform/Linux.cmake cmake-2.8.11.2/Modules/Platform/Linux.cmake
--- cmake-2.8.11.2-orig/Modules/Platform/Linux.cmake 2013-07-02 15:41:40.000000000 +0200
+++ cmake-2.8.11.2/Modules/Platform/Linux.cmake 2013-07-15 11:43:30.557888066 +0200
@@ -36,13 +36,8 @@
# checking the platform every time. This option is advanced enough
# that only package maintainers should need to adjust it. They are
# capable of providing a setting on the command line.
- if(EXISTS "/etc/debian_version")
- set(CMAKE_INSTALL_SO_NO_EXE 1 CACHE INTERNAL
- "Install .so files without execute permission.")
- else()
- set(CMAKE_INSTALL_SO_NO_EXE 0 CACHE INTERNAL
- "Install .so files without execute permission.")
- endif()
+ set(CMAKE_INSTALL_SO_NO_EXE 0 CACHE INTERNAL
+ "Install .so files without execute permission.")
endif()
# Match multiarch library directory names.
@@ -50,8 +45,3 @@
include(Platform/UnixPaths)
-# Debian has lib64 paths only for compatibility so they should not be
-# searched.
-if(EXISTS "/etc/debian_version")
- set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS FALSE)
-endif()
diff -ru -x '*~' cmake-2.8.11.2-orig/Modules/Platform/UnixPaths.cmake cmake-2.8.11.2/Modules/Platform/UnixPaths.cmake
--- cmake-2.8.11.2-orig/Modules/Platform/UnixPaths.cmake 2013-07-02 15:41:40.000000000 +0200
+++ cmake-2.8.11.2/Modules/Platform/UnixPaths.cmake 2013-07-15 11:42:02.949204549 +0200
@@ -31,58 +31,13 @@
# List common installation prefixes. These will be used for all
# search types.
-list(APPEND CMAKE_SYSTEM_PREFIX_PATH
- # Standard
- /usr/local /usr /
+list(APPEND CMAKE_SYSTEM_PREFIX_PATH "@glibc@")
- # CMake install location
- "${_CMAKE_INSTALL_DIR}"
+list(APPEND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES "@glibc@/lib")
- # Project install destination.
- "${CMAKE_INSTALL_PREFIX}"
- )
+list(APPEND CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES "@glibc@/include")
-# List common include file locations not under the common prefixes.
-list(APPEND CMAKE_SYSTEM_INCLUDE_PATH
- # Windows API on Cygwin
- /usr/include/w32api
-
- # X11
- /usr/X11R6/include /usr/include/X11
-
- # Other
- /usr/pkg/include
- /opt/csw/include /opt/include
- /usr/openwin/include
- )
-
-list(APPEND CMAKE_SYSTEM_LIBRARY_PATH
- # Windows API on Cygwin
- /usr/lib/w32api
-
- # X11
- /usr/X11R6/lib /usr/lib/X11
-
- # Other
- /usr/pkg/lib
- /opt/csw/lib /opt/lib
- /usr/openwin/lib
- )
-
-list(APPEND CMAKE_SYSTEM_PROGRAM_PATH
- /usr/pkg/bin
- )
-
-list(APPEND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES
- /lib /usr/lib /usr/lib32 /usr/lib64
- )
-
-list(APPEND CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES
- /usr/include
- )
-list(APPEND CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES
- /usr/include
- )
+list(APPEND CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES "@glibc@/include")
# Enable use of lib64 search path variants by default.
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS TRUE)