diff --git a/CMakeLists.txt b/CMakeLists.txt index 378043b8f2..475b6f96e5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -114,6 +114,9 @@ install(DIRECTORY FILES_MATCHING REGEX "\\.h(pp)?$" ) +# find Python before enabling pybind11 +find_package(Python REQUIRED COMPONENTS Development.Module) + # Define CMAKE_INSTALL_xxx: LIBDIR, INCLUDEDIR include(GNUInstallDirs) diff --git a/dpctl/CMakeLists.txt b/dpctl/CMakeLists.txt index 1de0bbf77d..e2914f6394 100644 --- a/dpctl/CMakeLists.txt +++ b/dpctl/CMakeLists.txt @@ -1,4 +1,4 @@ -find_package(Python REQUIRED COMPONENTS Development.Module NumPy) +find_package(Python REQUIRED COMPONENTS NumPy) # -t is to only Cythonize sources with timestamps newer than existing CXX files (if present) # -w is to set working directory (and correctly set __pyx_f[] array of filenames)