diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2021-02-12 18:56:54 +0100 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2021-02-12 21:55:39 +0100 |
commit | 7faa1a85a52f340fdd37c61be71fca4b4d827b21 (patch) | |
tree | 996e1b69ccca9d6a561dfe2e33e5f6e147f7da20 /media-sound/kid3 | |
parent | kde-plasma/kde-gtk-config: Drop 5.20.5 (r0) (diff) | |
download | gentoo-7faa1a85a52f340fdd37c61be71fca4b4d827b21.tar.gz gentoo-7faa1a85a52f340fdd37c61be71fca4b4d827b21.tar.bz2 gentoo-7faa1a85a52f340fdd37c61be71fca4b4d827b21.zip |
media-sound/kid3: Python is always required in BDEPEND
Closes: https://bugs.gentoo.org/769938
Package-Manager: Portage-3.0.14, Repoman-3.0.2
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'media-sound/kid3')
-rw-r--r-- | media-sound/kid3/files/kid3-3.8.5-tests-optional.patch | 75 | ||||
-rw-r--r-- | media-sound/kid3/kid3-3.8.5.ebuild | 5 |
2 files changed, 30 insertions, 50 deletions
diff --git a/media-sound/kid3/files/kid3-3.8.5-tests-optional.patch b/media-sound/kid3/files/kid3-3.8.5-tests-optional.patch index d5b74ca56137..44af299f13ce 100644 --- a/media-sound/kid3/files/kid3-3.8.5-tests-optional.patch +++ b/media-sound/kid3/files/kid3-3.8.5-tests-optional.patch @@ -1,33 +1,37 @@ -From 4efe62089eff54ac844c70382d432f2abb24c06e Mon Sep 17 00:00:00 2001 -From: Andreas Sturmlechner <asturm@gentoo.org> -Date: Sun, 31 Jan 2021 20:38:41 +0100 -Subject: [PATCH 1/2] Use include(CTest) and BUILD_TESTING to make Qt5Test and - Python optional +From fe096c5d05c95bfdcfae6a5976e242e324f4152d Mon Sep 17 00:00:00 2001 +From: Andreas Sturmlechner <andreas.sturmlechner@gmail.com> +Date: Fri, 5 Feb 2021 06:17:42 +0000 +Subject: [PATCH] Use include(CTest) and BUILD_TESTING to make tests optional Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> --- - CMakeLists.txt | 25 ++++++++++++++++--------- - 1 file changed, 16 insertions(+), 9 deletions(-) + CMakeLists.txt | 29 ++++++++++++++++++++--------- + src/CMakeLists.txt | 2 +- + 2 files changed, 21 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt -index 92d50265..557a208d 100644 +index 92d50265..ee476ac5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -211,8 +211,11 @@ endif() +@@ -211,8 +211,15 @@ endif() set(CFG_QMLSRCDIR "${kid3_SOURCE_DIR}/src/qml") find_package(Threads) -set(Python_ADDITIONAL_VERSIONS 3) -find_package(PythonInterp REQUIRED) +include(CTest) -+if(BUILD_TESTING) ++if(CMAKE_VERSION VERSION_LESS 3.12.0) + set(Python_ADDITIONAL_VERSIONS 3) + find_package(PythonInterp REQUIRED) ++ # PythonInterp sets PYTHON_EXECUTABLE ++else() ++ find_package(Python3 COMPONENTS Interpreter REQUIRED) ++ set(PYTHON_EXECUTABLE "${Python3_EXECUTABLE}") +endif() include (CheckCXXSourceCompiles) include (CheckCXXCompilerFlag) include (CheckLibraryExists) -@@ -256,7 +259,10 @@ else() +@@ -256,7 +263,10 @@ else() find_package(Qt5Core) endif() if(Qt5Core_FOUND) @@ -39,7 +43,7 @@ index 92d50265..557a208d 100644 if(WITH_DBUS) set(_qtComponents ${_qtComponents} DBus) endif() -@@ -472,12 +478,13 @@ if(ANDROID) +@@ -472,12 +482,13 @@ if(ANDROID) endif() @@ -59,41 +63,18 @@ index 92d50265..557a208d 100644 endif() --- -2.30.0 - - -From 1e264e918686d5d09a5457513f3aadeea25d6e5e Mon Sep 17 00:00:00 2001 -From: Andreas Sturmlechner <asturm@gentoo.org> -Date: Sun, 31 Jan 2021 23:43:49 +0100 -Subject: [PATCH 2/2] Use CMake FindPython3 module if available (CMake >=3.12) - -Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org> ---- - CMakeLists.txt | 10 ++++++++-- - 1 file changed, 8 insertions(+), 2 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 557a208d..706167e6 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -213,8 +213,14 @@ set(CFG_QMLSRCDIR "${kid3_SOURCE_DIR}/src/qml") - find_package(Threads) - include(CTest) - if(BUILD_TESTING) -- set(Python_ADDITIONAL_VERSIONS 3) -- find_package(PythonInterp REQUIRED) -+ if(CMAKE_VERSION VERSION_LESS 3.12.0) -+ set(Python_ADDITIONAL_VERSIONS 3) -+ find_package(PythonInterp REQUIRED) -+ # PythonInterp sets PYTHON_EXECUTABLE -+ else() -+ find_package(Python3 COMPONENTS Interpreter REQUIRED) -+ set(PYTHON_EXECUTABLE "${Python3_EXECUTABLE}") -+ endif() +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index c6c703ac..db067265 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -8,6 +8,6 @@ if(WITH_QML) + add_subdirectory(qml) + endif() + +-if(BUILD_TEST_APP) ++if(BUILD_TESTING AND BUILD_TEST_APP) + add_subdirectory(test) endif() - include (CheckCXXSourceCompiles) - include (CheckCXXCompilerFlag) -- -2.30.0 +GitLab diff --git a/media-sound/kid3/kid3-3.8.5.ebuild b/media-sound/kid3/kid3-3.8.5.ebuild index 734a8c024651..8ed70dc49ede 100644 --- a/media-sound/kid3/kid3-3.8.5.ebuild +++ b/media-sound/kid3/kid3-3.8.5.ebuild @@ -21,10 +21,9 @@ IUSE="acoustid flac kde mp3 mp4 +mpris +taglib test vorbis" REQUIRED_USE="flac? ( vorbis )" RESTRICT+=" !test? ( test )" -BDEPEND=" +BDEPEND="${PYTHON_DEPS} dev-qt/linguist-tools:5 kde? ( kde-frameworks/extra-cmake-modules:5 ) - test? ( ${PYTHON_DEPS} ) " COMMON_DEPEND=" dev-qt/qtcore:5 @@ -82,6 +81,7 @@ src_prepare() { src_configure() { local mycmakeargs=( + -DPython3_EXECUTABLE="${PYTHON}" -DWITH_CHROMAPRINT=$(usex acoustid) -DWITH_DBUS=$(usex mpris) -DWITH_FLAC=$(usex flac) @@ -91,7 +91,6 @@ src_configure() { -DBUILD_TESTING=$(usex test) -DWITH_VORBIS=$(usex vorbis) ) - use test && mycmakeargs+=( -DPython3_EXECUTABLE="${PYTHON}" ) if use kde ; then mycmakeargs+=( "-DWITH_APPS=KDE;CLI" ) |