diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-06-19 10:57:56 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-06-19 10:57:56 +0400 |
commit | 145944d66f8364c82bdc83dcd57774284b775add (patch) | |
tree | b1b0e28d008402c3d379b644321648b4f95977ef /build_files/cmake/Modules | |
parent | f31bae0aabe47b928a8c77020a798e815ed8b70f (diff) |
cmake:
new macro file_list_suffix() for adding a suffix to every file in a path before the file extension.
useful to create names for debug libs on windows.
Diffstat (limited to 'build_files/cmake/Modules')
-rw-r--r-- | build_files/cmake/Modules/FindPythonLibsUnix.cmake | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/build_files/cmake/Modules/FindPythonLibsUnix.cmake b/build_files/cmake/Modules/FindPythonLibsUnix.cmake index 729771f0a52..07d95a53dc2 100644 --- a/build_files/cmake/Modules/FindPythonLibsUnix.cmake +++ b/build_files/cmake/Modules/FindPythonLibsUnix.cmake @@ -2,7 +2,7 @@ # # PYTHON_VERSION # PYTHON_INCLUDE_DIRS -# PYTHON_LIBRARY +# PYTHON_LIBRARIES # PYTHON_LIBPATH # PYTHON_LINKFLAGS # PYTHON_ROOT_DIR, The base directory to search for Python. @@ -45,18 +45,18 @@ foreach(_CURRENT_ABI_FLAGS ${_python_ABI_FLAGS}) PATH_SUFFIXES include/python${PYTHON_VERSION}${_CURRENT_ABI_FLAGS} ) - find_library(PYTHON_LIBRARY + find_library(PYTHON_LIBRARIES NAMES "python${PYTHON_VERSION}${_CURRENT_ABI_FLAGS}" HINTS ${_python_SEARCH_DIRS} PATH_SUFFIXES lib64 lib ) - if((EXISTS ${PYTHON_LIBRARY}) AND (EXISTS ${PYTHON_INCLUDE_DIR})) + if((EXISTS ${PYTHON_LIBRARIES}) AND (EXISTS ${PYTHON_INCLUDE_DIR})) break() else() # ensure we dont find values from 2 different ABI versions unset(PYTHON_INCLUDE_DIR CACHE) - unset(PYTHON_LIBRARY CACHE) + unset(PYTHON_LIBRARIES CACHE) endif() endforeach() @@ -70,19 +70,19 @@ unset(_python_SEARCH_DIRS) # all listed variables are TRUE include(FindPackageHandleStandardArgs) FIND_PACKAGE_HANDLE_STANDARD_ARGS(PythonLibsUnix DEFAULT_MSG - PYTHON_LIBRARY PYTHON_INCLUDE_DIR) + PYTHON_LIBRARIES PYTHON_INCLUDE_DIR) if(PYTHONLIBSUNIX_FOUND) # Assign cache items set(PYTHON_INCLUDE_DIRS ${PYTHON_INCLUDE_DIR} CACHE STRING "") - set(PYTHON_LIBRARY ${PYTHON_LIBRARY} CACHE STRING "") + set(PYTHON_LIBRARIES ${PYTHON_LIBRARIES} CACHE STRING "") # not used # set(PYTHON_BINARY ${PYTHON_EXECUTABLE} CACHE STRING "") mark_as_advanced( PYTHON_INCLUDE_DIRS PYTHON_INCLUDE_DIR - PYTHON_LIBRARY + PYTHON_LIBRARIES ) endif() |