File tree Expand file tree Collapse file tree
GoogleTest/src/itkgoogletest/googletest/cmake Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -141,4 +141,4 @@ set(ITK_WRAP_complex_double @ITK_WRAP_complex_double@)
141141set (ITK_WRAP_IMAGE_DIMS "@ITK_WRAP_IMAGE_DIMS@" )
142142set (ITK_WRAP_VECTOR_COMPONENTS "@ITK_WRAP_VECTOR_COMPONENTS@" )
143143
144- set (ITK_WRAP_PYTHON_VERSION "@PYTHON_VERSION_STRING @" )
144+ set (ITK_WRAP_PYTHON_VERSION "@Python3_VERSION @" )
Original file line number Diff line number Diff line change 11cmake_minimum_required (VERSION 3.16.3 )
22project (ITKBridgeNumPy)
33
4- set (ITKBridgeNumPy_SYSTEM_INCLUDE_DIRS "${PYTHON_INCLUDE_DIR } " )
4+ set (ITKBridgeNumPy_SYSTEM_INCLUDE_DIRS "${Python3_INCLUDE_DIRS } " )
55
66if (NOT ITK_SOURCE_DIR )
77 find_package (ITK REQUIRED )
Original file line number Diff line number Diff line change @@ -455,10 +455,10 @@ endif()
455455
456456#-----------------------------------------------------------------------------
457457# Python install
458- #find_package(PythonInterp REQUIRED)
458+ #find_package(Python3 COMPONENTS Interpreter REQUIRED)
459459#macro(GET_PYTHON_SITE_PACKAGE dir)
460460# execute_process(
461- # COMMAND ${PYTHON_EXECUTABLE } "-c" "from distutils import sysconfig; print sysconfig.get_python_lib()"
461+ # COMMAND ${Python3_EXECUTABLE } "-c" "from distutils import sysconfig; print sysconfig.get_python_lib()"
462462# #WORKING_DIRECTORY @LIBRARY_OUTPUT_PATH@
463463# RESULT_VARIABLE import_res
464464# OUTPUT_VARIABLE import_output
Original file line number Diff line number Diff line change @@ -246,12 +246,6 @@ function(cxx_executable name dir libs)
246246 ${name} "${cxx_default} " "${libs} " "${dir} /${name} .cc" ${ARGN} )
247247endfunction ()
248248
249- # Sets PYTHONINTERP_FOUND and PYTHON_EXECUTABLE.
250- # ITK The PythonInterp package finding contaminates the cmake cache and
251- # ITK may find a different version than is use by wrapping or documentation
252- # ITK generation. DO NOT USE find_package(PythonInterp)
253- # ITK find_package(PythonInterp)
254-
255249# cxx_test_with_flags(name cxx_flags libs srcs...)
256250#
257251# creates a named C++ test that depends on the given libs and is built
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ if (ITK_BUILD_DOCUMENTATION)
9797 file (COPY workbox-cli-config.js serviceWorker.js.in
9898 DESTINATION ${ITK_BINARY_DIR } /Utilities/Doxygen/ )
9999
100- execute_process (COMMAND ${PYTHON_EXECUTABLE } "${CMAKE_CURRENT_LIST_DIR } /datetime.py"
100+ execute_process (COMMAND ${Python3_EXECUTABLE } "${CMAKE_CURRENT_LIST_DIR } /datetime.py"
101101 RESULT_VARIABLE CMD_RESULT
102102 OUTPUT_VARIABLE _DATETIME )
103103
Original file line number Diff line number Diff line change @@ -392,7 +392,7 @@ ${DO_NOT_WAIT_FOR_THREADS_CALLS}
392392
393393 # Link the modules together
394394 target_link_libraries (${lib} LINK_PUBLIC ${WRAPPER_LIBRARY_LINK_LIBRARIES} )
395- itk_target_link_libraries_with_dynamic_lookup (${lib} LINK_PUBLIC ${PYTHON_LIBRARY } )
395+ itk_target_link_libraries_with_dynamic_lookup (${lib} LINK_PUBLIC ${Python3_LIBRARIES } )
396396
397397 if (USE_COMPILER_HIDDEN_VISIBILITY)
398398 # Prefer to use target properties supported by newer cmake
You can’t perform that action at this time.
0 commit comments