From ffcbf233d16df31ddc165a0844f559c8c35fc9f7 Mon Sep 17 00:00:00 2001 From: baldurk Date: Thu, 8 Jun 2017 11:13:43 +0100 Subject: [PATCH] Link against python in python modules for now. Refs #639 * This really isn't ideal as it means the python module will only work with that specific major.minor version of python, when it could in theory work with any python version above 3.2 or so, depending on what features are used. * Since we're not distributing these modules yet though, add this linking to support -Wl,--no-undefined. --- qrenderdoc/Code/pyrenderdoc/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/qrenderdoc/Code/pyrenderdoc/CMakeLists.txt b/qrenderdoc/Code/pyrenderdoc/CMakeLists.txt index a457e2e82..151094546 100644 --- a/qrenderdoc/Code/pyrenderdoc/CMakeLists.txt +++ b/qrenderdoc/Code/pyrenderdoc/CMakeLists.txt @@ -35,6 +35,9 @@ set(CMAKE_SKIP_BUILD_RPATH TRUE) set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE) set(CMAKE_INSTALL_RPATH "$ORIGIN/:$ORIGIN/../lib/") +# Add python library +set (CMAKE_SHARED_LINKER_FLAGS "${PYTHON_LIBRARY} ${CMAKE_SHARED_LINKER_FLAGS}") + add_library(_renderdoc SHARED ${CMAKE_BINARY_DIR}/qrenderdoc/renderdoc_python.cxx pyrenderdoc_stub.cpp)