ayaports/backports/py3-arcus/cmake.patch

32 lines
1 KiB
Diff

--- ./CMakeLists.txt.orig
+++ ./CMakeLists.txt
@@ -2,22 +2,22 @@
project(pyarcus)
cmake_minimum_required(VERSION 3.20)
-find_package(protobuf REQUIRED)
-find_package(cpython REQUIRED)
-find_package(arcus REQUIRED)
+list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
-find_package(standardprojectsettings REQUIRED)
-find_package(sipbuildtool REQUIRED)
+find_package(Protobuf REQUIRED)
+find_package(Python REQUIRED COMPONENTS Interpreter Development)
+find_package(Arcus REQUIRED)
+find_package(SIP 6.5.0 REQUIRED)
+
add_library(pyArcus INTERFACE src/PythonMessage.cpp)
-use_threads(pyArcus)
target_include_directories(pyArcus
INTERFACE
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include/>
)
-target_link_libraries(pyArcus INTERFACE arcus::arcus protobuf::libprotobuf cpython::cpython)
+target_link_libraries(pyArcus INTERFACE Arcus protobuf::libprotobuf Python::Python)
add_sip_module(pyArcus)
install_sip_module(pyArcus)