vcpkg/ports/shiva/find_python_and_no_copy_dll.patch
Yury Bura 1ec3d05438
[pybind11] update to v2.10.4 (#32194)
* [pybind11] update to v2.10.4, clean-up redundant dependency, add usage
2023-07-10 10:52:11 -07:00

26 lines
856 B
Diff

diff --git a/modules/python/CMakeLists.txt b/modules/python/CMakeLists.txt
index eef14ee..30130ba 100644
--- a/modules/python/CMakeLists.txt
+++ b/modules/python/CMakeLists.txt
@@ -1,10 +1,10 @@
include(CMakeSources.cmake)
set(MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR})
+find_package(Python COMPONENTS Interpreter Development)
find_package(pybind11 CONFIG REQUIRED)
-
-if (WIN32)
+if (FALSE)
## We need pyton dll
file(GLOB PYTHON_DLL ${PYTHON_LIBRARIES}/../*.dll)
@@ -19,6 +19,6 @@ endif ()
CREATE_MODULE(shiva::pyscripting "${MODULE_SOURCES}" ${MODULE_PATH} "python")
-target_link_libraries(pyscripting INTERFACE shiva::ecs shiva::input pybind11::embed pybind11::module)
+target_link_libraries(pyscripting INTERFACE shiva::ecs shiva::input pybind11::embed pybind11::module Python::Module)
AUTO_TARGETS_MODULE_INSTALL(pyscripting)