diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2020-08-25 10:45:55 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2020-08-25 10:45:55 +0100 |
commit | 3cf7c3ef441822c889356fd1812ebf2944a59851 (patch) | |
tree | c513fe68548b40365c1c2ebfe35c58ad431cdd77 /kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch | |
parent | 05b8b0e0af1d72e51a3ee61522941bf7605cd01c (diff) |
gentoo resync : 25.08.2020
Diffstat (limited to 'kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch')
-rw-r--r-- | kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch | 91 |
1 files changed, 91 insertions, 0 deletions
diff --git a/kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch b/kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch new file mode 100644 index 000000000000..bd0c13ad3772 --- /dev/null +++ b/kde-apps/kig/files/kig-20.08.70-cmake-boostpython.patch @@ -0,0 +1,91 @@ +From 39bf05d48f899612dffa07c73ac276f52820a7c9 Mon Sep 17 00:00:00 2001 +From: Andreas Sturmlechner <asturm@gentoo.org> +Date: Mon, 13 Jul 2020 00:41:25 +0200 +Subject: [PATCH] Use CMake's own FindBoost module to detect Boost Python + +Introduces BOOSTPYTHON_VERSION_MAJOR_MINOR for packaging. + +Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> +--- + CMakeLists.txt | 26 ++++++++++++-------------- + 1 file changed, 12 insertions(+), 14 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e65585fb..e07a4dc6 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -51,7 +51,8 @@ endif() + + include(KigConfigureChecks.cmake) + +-find_package(BoostPython) ++set(BOOSTPYTHON_VERSION_MAJOR_MINOR python37 CACHE STRING "Version of BoostPython to feed CMake's FindBoost") ++find_package(Boost 1.70 COMPONENTS ${BOOSTPYTHON_VERSION_MAJOR_MINOR}) + + add_subdirectory( doc ) + add_subdirectory( icons ) +@@ -61,15 +62,15 @@ add_subdirectory( macros ) + add_subdirectory( data ) + add_subdirectory( pykig ) + +-if(BoostPython_FOUND) ++if(Boost_FOUND) ++ find_package(PythonLibs 3 REQUIRED) ++ include_directories(${PYTHON_INCLUDE_DIRS}) + add_subdirectory( scripting ) + add_definitions(-DKIG_ENABLE_PYTHON_SCRIPTING) +-endif(BoostPython_FOUND) ++endif() + + set_package_properties( +- BoostPython PROPERTIES +- DESCRIPTION "Python scripting support in Boost" +- URL "https://www.boost.org/" ++ Boost PROPERTIES + TYPE OPTIONAL + PURPOSE "Kig can optionally use Boost.Python for Python scripting" + ) +@@ -85,9 +86,6 @@ set_package_properties( + feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) + + include_directories( ${CMAKE_SOURCE_DIR}/modes ) +-if(BoostPython_FOUND) +- include_directories(${BoostPython_INCLUDE_DIRS}) +-endif(BoostPython_FOUND) + + # kigpart + +@@ -225,7 +223,7 @@ ki18n_wrap_ui(kigpart_PART_SRCS + misc/kigcoordinateprecisiondialog.ui + ) + +-if(BoostPython_FOUND) ++if(Boost_FOUND) + set(kigpart_PART_SRCS ${kigpart_PART_SRCS} + modes/popup/scriptactionsprovider.cc + scripting/newscriptwizard.cc +@@ -236,7 +234,7 @@ if(BoostPython_FOUND) + ) + + kde_source_files_enable_exceptions(scripting/python_scripter.cc) +-endif(BoostPython_FOUND) ++endif() + + + add_library(kigpart MODULE ${kigpart_PART_SRCS}) +@@ -256,9 +254,9 @@ target_link_libraries(kigpart + ${KDE5_KUTILS_LIBS} + ) + +-if(BoostPython_FOUND) +- target_link_libraries(kigpart ${BoostPython_LIBRARIES} ${KDE5_KTEXTEDITOR_LIBS}) +-endif(BoostPython_FOUND) ++if(Boost_FOUND) ++ target_link_libraries(kigpart Boost::${BOOSTPYTHON_VERSION_MAJOR_MINOR} ${PYTHON_LIBRARIES}) ++endif() + + if (Qt5XmlPatterns_FOUND) + target_link_libraries(kigpart Qt5::XmlPatterns) +-- +2.27.0 + |