commit: 9c71027b57506d54c4d3c33edd4d0e8ee40ffb0f Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> AuthorDate: Tue Jan 21 16:05:42 2020 +0000 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> CommitDate: Tue Jan 21 16:07:06 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9c71027b
kde-apps/kig: Fix crash upon exit when using scripting Package-Manager: Portage-2.3.84, Repoman-2.3.20 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org> .../kig/files/kig-19.08.3-scripter-crash.patch | 29 +++++++++ kde-apps/kig/files/kig-4.12.0-boostpython.patch | 2 +- kde-apps/kig/kig-19.08.3-r2.ebuild | 73 ++++++++++++++++++++++ kde-apps/kig/kig-19.12.1-r1.ebuild | 72 +++++++++++++++++++++ 4 files changed, 175 insertions(+), 1 deletion(-) diff --git a/kde-apps/kig/files/kig-19.08.3-scripter-crash.patch b/kde-apps/kig/files/kig-19.08.3-scripter-crash.patch new file mode 100644 index 00000000000..9540e9044f3 --- /dev/null +++ b/kde-apps/kig/files/kig-19.08.3-scripter-crash.patch @@ -0,0 +1,29 @@ +From 211f8501ec4cf77ed68253783d58a662b5513612 Mon Sep 17 00:00:00 2001 +From: Maurizio Paolini <paol...@dmf.unicatt.it> +Date: Sat, 11 Jan 2020 19:50:33 +0100 +Subject: Fix crash upon exit after transition python2 -> python3 when using + scripting (bug #416037) + +Reviewed By: kkevin +Differential Revision: https://phabricator.kde.org/D12833 +CCBUG: 416037 +--- + scripting/python_scripter.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/scripting/python_scripter.cc b/scripting/python_scripter.cc +index bb5db39..3edec77 100644 +--- a/scripting/python_scripter.cc ++++ b/scripting/python_scripter.cc +@@ -427,8 +427,8 @@ PythonScripter::PythonScripter() + PythonScripter::~PythonScripter() + { + PyErr_Clear(); +- Py_Finalize(); + delete d; ++ Py_FinalizeEx(); + } + + class CompiledPythonScript::Private +-- +cgit v1.1 diff --git a/kde-apps/kig/files/kig-4.12.0-boostpython.patch b/kde-apps/kig/files/kig-4.12.0-boostpython.patch index 7a4b878c6bc..c9ca1b2f9d0 100644 --- a/kde-apps/kig/files/kig-4.12.0-boostpython.patch +++ b/kde-apps/kig/files/kig-4.12.0-boostpython.patch @@ -14,4 +14,4 @@ index 2ccc161..02d9bf6 100644 + pkg_check_modules(_python python-${_pyver}) if(${_pyver}_FOUND) cmake_push_check_state() - set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${${_pyver}_INCLUDE_DIRS}) \ No newline at end of file + set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${${_pyver}_INCLUDE_DIRS}) diff --git a/kde-apps/kig/kig-19.08.3-r2.ebuild b/kde-apps/kig/kig-19.08.3-r2.ebuild new file mode 100644 index 00000000000..e6f4820bb30 --- /dev/null +++ b/kde-apps/kig/kig-19.08.3-r2.ebuild @@ -0,0 +1,73 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +ECM_HANDBOOK="forceoptional" +ECM_TEST="true" +PYTHON_COMPAT=( python3_{6,7,8} ) +KFMIN=5.60.0 +QTMIN=5.12.3 +inherit python-single-r1 ecm kde.org + +DESCRIPTION="KDE Interactive Geometry tool" +HOMEPAGE="https://kde.org/applications/education/org.kde.kig +https://edu.kde.org/kig/" + +LICENSE="GPL-2" # TODO: CHECK +SLOT="5" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="geogebra scripting" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RDEPEND="${PYTHON_DEPS} + >=dev-qt/qtgui-${QTMIN}:5 + >=dev-qt/qtprintsupport-${QTMIN}:5 + >=dev-qt/qtsvg-${QTMIN}:5 + >=dev-qt/qtwidgets-${QTMIN}:5 + >=dev-qt/qtxml-${QTMIN}:5 + >=kde-frameworks/karchive-${KFMIN}:5 + >=kde-frameworks/kcompletion-${KFMIN}:5 + >=kde-frameworks/kconfig-${KFMIN}:5 + >=kde-frameworks/kconfigwidgets-${KFMIN}:5 + >=kde-frameworks/kcoreaddons-${KFMIN}:5 + >=kde-frameworks/kcrash-${KFMIN}:5 + >=kde-frameworks/ki18n-${KFMIN}:5 + >=kde-frameworks/kiconthemes-${KFMIN}:5 + >=kde-frameworks/kparts-${KFMIN}:5 + >=kde-frameworks/kservice-${KFMIN}:5 + >=kde-frameworks/kwidgetsaddons-${KFMIN}:5 + >=kde-frameworks/kxmlgui-${KFMIN}:5 + geogebra? ( >=dev-qt/qtxmlpatterns-${QTMIN}:5 ) + scripting? ( >=dev-libs/boost-1.48:=[python,${PYTHON_USEDEP}] ) +" +DEPEND="${RDEPEND} + >=kde-frameworks/ktexteditor-${KFMIN}:5 +" + +PATCHES=( + "${FILESDIR}"/${PN}-4.12.0-boostpython.patch + "${FILESDIR}"/${P}-scripter-python3.patch + "${FILESDIR}"/${P}-scripter-crash.patch + "${FILESDIR}"/${P}-pykig-python3.patch +) + +pkg_setup() { + python-single-r1_pkg_setup + ecm_pkg_setup +} + +src_prepare() { + ecm_src_prepare + python_fix_shebang . +} + +src_configure() { + local mycmakeargs=( + $(cmake_use_find_package geogebra Qt5XmlPatterns) + $(cmake_use_find_package scripting BoostPython) + ) + + ecm_src_configure +} diff --git a/kde-apps/kig/kig-19.12.1-r1.ebuild b/kde-apps/kig/kig-19.12.1-r1.ebuild new file mode 100644 index 00000000000..97c83d4330f --- /dev/null +++ b/kde-apps/kig/kig-19.12.1-r1.ebuild @@ -0,0 +1,72 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +ECM_HANDBOOK="forceoptional" +ECM_TEST="true" +PYTHON_COMPAT=( python3_{6,7,8} ) +KFMIN=5.63.0 +QTMIN=5.12.3 +inherit python-single-r1 ecm kde.org + +DESCRIPTION="KDE Interactive Geometry tool" +HOMEPAGE="https://kde.org/applications/education/org.kde.kig +https://edu.kde.org/kig/" + +LICENSE="GPL-2" # TODO: CHECK +SLOT="5" +KEYWORDS="~amd64 ~arm64 ~x86" +IUSE="geogebra scripting" + +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +RDEPEND="${PYTHON_DEPS} + >=dev-qt/qtgui-${QTMIN}:5 + >=dev-qt/qtprintsupport-${QTMIN}:5 + >=dev-qt/qtsvg-${QTMIN}:5 + >=dev-qt/qtwidgets-${QTMIN}:5 + >=dev-qt/qtxml-${QTMIN}:5 + >=kde-frameworks/karchive-${KFMIN}:5 + >=kde-frameworks/kcompletion-${KFMIN}:5 + >=kde-frameworks/kconfig-${KFMIN}:5 + >=kde-frameworks/kconfigwidgets-${KFMIN}:5 + >=kde-frameworks/kcoreaddons-${KFMIN}:5 + >=kde-frameworks/kcrash-${KFMIN}:5 + >=kde-frameworks/ki18n-${KFMIN}:5 + >=kde-frameworks/kiconthemes-${KFMIN}:5 + >=kde-frameworks/kparts-${KFMIN}:5 + >=kde-frameworks/kservice-${KFMIN}:5 + >=kde-frameworks/kwidgetsaddons-${KFMIN}:5 + >=kde-frameworks/kxmlgui-${KFMIN}:5 + geogebra? ( >=dev-qt/qtxmlpatterns-${QTMIN}:5 ) + scripting? ( >=dev-libs/boost-1.48:=[python,${PYTHON_USEDEP}] ) +" +DEPEND="${RDEPEND} + >=kde-frameworks/ktexteditor-${KFMIN}:5 +" + +PATCHES=( + "${FILESDIR}"/${PN}-4.12.0-boostpython.patch + "${FILESDIR}"/${PN}-19.08.3-pykig-python3.patch + "${FILESDIR}"/${PN}-19.08.3-scripter-crash.patch +) + +pkg_setup() { + python-single-r1_pkg_setup + ecm_pkg_setup +} + +src_prepare() { + ecm_src_prepare + python_fix_shebang . +} + +src_configure() { + local mycmakeargs=( + $(cmake_use_find_package geogebra Qt5XmlPatterns) + $(cmake_use_find_package scripting BoostPython) + ) + + ecm_src_configure +}