Skip to content

Commit 1bce181

Browse files
committed
Refactor CMakeLists.txt to unify Python detection and improve pybind11 integration
1 parent 875c84d commit 1bce181

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

CMakeLists.txt

+3-4
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,10 @@ endif ()
4242

4343
add_executable(vpmr src/VPMR.cpp)
4444

45-
find_package(Python3 COMPONENTS Development Interpreter)
46-
if (Python3_FOUND)
45+
find_package(Python 3 COMPONENTS Development Interpreter)
46+
if (Python_FOUND)
4747
add_subdirectory(pybind11)
48-
message(STATUS "Python3: ${Python3_VERSION}")
49-
include_directories(${Python3_INCLUDE_DIRS})
48+
message(STATUS "Python3: ${Python_VERSION}")
5049

5150
pybind11_add_module(_pyvpmr src/VPMR.cpp)
5251
target_compile_definitions(_pyvpmr PRIVATE PYVPMR)

0 commit comments

Comments
 (0)