[Cmake-commits] CMake branch, next, updated. v3.3.1-3052-g8d64312
Brad King
brad.king at kitware.com
Thu Sep 17 12:44:30 EDT 2015
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, next has been updated
via 8d64312707846dfb1611c97f2d5986e04389d552 (commit)
via 19934b67e96c91f927a1887ce85a3e6b30b2f9a0 (commit)
from 13731202f402f6e9d8227560fcc1278f483b530b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=8d64312707846dfb1611c97f2d5986e04389d552
commit 8d64312707846dfb1611c97f2d5986e04389d552
Merge: 1373120 19934b6
Author: Brad King <brad.king at kitware.com>
AuthorDate: Thu Sep 17 12:44:29 2015 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Sep 17 12:44:29 2015 -0400
Merge topic 'FindPython-updates' into next
19934b67 FindPythonLibs: unset temporary _PREFIX variable
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=19934b67e96c91f927a1887ce85a3e6b30b2f9a0
commit 19934b67e96c91f927a1887ce85a3e6b30b2f9a0
Author: David Gobbi <david.gobbi at gmail.com>
AuthorDate: Thu Sep 17 10:00:03 2015 -0600
Commit: Brad King <brad.king at kitware.com>
CommitDate: Thu Sep 17 12:43:56 2015 -0400
FindPythonLibs: unset temporary _PREFIX variable
To avoid pollution, unset variables that are only meant for local use.
diff --git a/Modules/FindPythonLibs.cmake b/Modules/FindPythonLibs.cmake
index 91cf49b..68e1228 100644
--- a/Modules/FindPythonLibs.cmake
+++ b/Modules/FindPythonLibs.cmake
@@ -53,16 +53,18 @@
set(_Python_LIBRARY_PATH_HINT)
if(PYTHON_EXECUTABLE)
if(WIN32)
- get_filename_component(_PREFIX ${PYTHON_EXECUTABLE} PATH)
- if(_PREFIX)
- set(_Python_LIBRARY_PATH_HINT ${_PREFIX}/libs)
+ get_filename_component(_Python_PREFIX ${PYTHON_EXECUTABLE} PATH)
+ if(_Python_PREFIX)
+ set(_Python_LIBRARY_PATH_HINT ${_Python_PREFIX}/libs)
endif()
+ unset(_Python_PREFIX)
else()
- get_filename_component(_PREFIX ${PYTHON_EXECUTABLE} PATH)
- get_filename_component(_PREFIX ${_PREFIX} PATH)
- if(_PREFIX)
- set(_Python_LIBRARY_PATH_HINT ${_PREFIX}/lib)
+ get_filename_component(_Python_PREFIX ${PYTHON_EXECUTABLE} PATH)
+ get_filename_component(_Python_PREFIX ${_Python_PREFIX} PATH)
+ if(_Python_PREFIX)
+ set(_Python_LIBRARY_PATH_HINT ${_Python_PREFIX}/lib)
endif()
+ unset(_Python_PREFIX)
endif()
endif()
@@ -175,11 +177,12 @@ foreach(_CURRENT_VERSION ${_Python_VERSIONS})
# Use the library's install prefix as a hint
set(_Python_INCLUDE_PATH_HINT)
- get_filename_component(_PREFIX ${PYTHON_LIBRARY} PATH)
- get_filename_component(_PREFIX ${_PREFIX} PATH)
- if(_PREFIX)
- set(_Python_INCLUDE_PATH_HINT ${_PREFIX}/include)
+ get_filename_component(_Python_PREFIX ${PYTHON_LIBRARY} PATH)
+ get_filename_component(_Python_PREFIX ${_Python_PREFIX} PATH)
+ if(_Python_PREFIX)
+ set(_Python_INCLUDE_PATH_HINT ${_Python_PREFIX}/include)
endif()
+ unset(_Python_PREFIX)
# Add framework directories to the search paths
set(PYTHON_FRAMEWORK_INCLUDES)
-----------------------------------------------------------------------
Summary of changes:
Modules/FindPythonLibs.cmake | 25 ++++++++++++++-----------
1 file changed, 14 insertions(+), 11 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list