build: Force cmake to find PythonInterp and PythonLibs v2.x

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
This commit is contained in:
Sylvain Munaut 2013-07-26 21:08:56 +02:00
parent 27adfdd236
commit 7a9166f905
3 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ if(PYTHON_EXECUTABLE)
else(PYTHON_EXECUTABLE) else(PYTHON_EXECUTABLE)
#use the built-in find script #use the built-in find script
find_package(PythonInterp) find_package(PythonInterp 2)
#and if that fails use the find program routine #and if that fails use the find program routine
if(NOT PYTHONINTERP_FOUND) if(NOT PYTHONINTERP_FOUND)

View File

@ -114,7 +114,7 @@ macro(GR_SWIG_MAKE name)
endif() endif()
#append additional include directories #append additional include directories
find_package(PythonLibs) find_package(PythonLibs 2)
list(APPEND GR_SWIG_INCLUDE_DIRS ${PYTHON_INCLUDE_PATH}) #deprecated name (now dirs) list(APPEND GR_SWIG_INCLUDE_DIRS ${PYTHON_INCLUDE_PATH}) #deprecated name (now dirs)
list(APPEND GR_SWIG_INCLUDE_DIRS ${PYTHON_INCLUDE_DIRS}) list(APPEND GR_SWIG_INCLUDE_DIRS ${PYTHON_INCLUDE_DIRS})
list(APPEND GR_SWIG_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}) list(APPEND GR_SWIG_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR})

View File

@ -21,7 +21,7 @@
# Include swig generation macros # Include swig generation macros
######################################################################## ########################################################################
find_package(SWIG) find_package(SWIG)
find_package(PythonLibs) find_package(PythonLibs 2)
if(NOT SWIG_FOUND OR NOT PYTHONLIBS_FOUND) if(NOT SWIG_FOUND OR NOT PYTHONLIBS_FOUND)
return() return()
endif() endif()