diff options
author | Andreas Sturmlechner <asturm@gentoo.org> | 2023-09-03 12:48:37 +0200 |
---|---|---|
committer | Andreas Sturmlechner <asturm@gentoo.org> | 2023-09-03 14:18:06 +0200 |
commit | f00d74be68cdafcc64ae0fe4090f5505243d4db7 (patch) | |
tree | 589b437c6f6836ac74fb89a12488e52701401f85 /media-gfx/nomacs | |
parent | sci-libs/stellarsolver: add 2.5 (diff) | |
download | gentoo-f00d74be68cdafcc64ae0fe4090f5505243d4db7.tar.gz gentoo-f00d74be68cdafcc64ae0fe4090f5505243d4db7.tar.bz2 gentoo-f00d74be68cdafcc64ae0fe4090f5505243d4db7.zip |
media-gfx/nomacs: update EAPI 7 -> 8, drop all sed modifications
Bug: https://bugs.gentoo.org/847112
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'media-gfx/nomacs')
-rw-r--r-- | media-gfx/nomacs/files/nomacs-3.16.224-libdir-plugins.patch | 23 | ||||
-rw-r--r-- | media-gfx/nomacs/files/nomacs-3.16.224-libdir.patch | 30 | ||||
-rw-r--r-- | media-gfx/nomacs/nomacs-3.16.224-r6.ebuild | 83 |
3 files changed, 136 insertions, 0 deletions
diff --git a/media-gfx/nomacs/files/nomacs-3.16.224-libdir-plugins.patch b/media-gfx/nomacs/files/nomacs-3.16.224-libdir-plugins.patch new file mode 100644 index 000000000000..0c613929add0 --- /dev/null +++ b/media-gfx/nomacs/files/nomacs-3.16.224-libdir-plugins.patch @@ -0,0 +1,23 @@ +From e1d32cd424462b2ac414d3a4ea3e1285d5ca2aef Mon Sep 17 00:00:00 2001 +From: Markus Diem <diemmarkus@gmail.com> +Date: Mon, 27 Jul 2020 13:11:31 +0200 +Subject: [PATCH] patches wrong plugin installation path + +- thanks to @tieugene +--- + ImageLounge/plugins/cmake/Utils.cmake | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cmake/Utils.cmake b/cmake/Utils.cmake +index f2d1b62..5578aa7 100644 +--- a/ImageLounge/plugins/cmake/Utils.cmake ++++ b/ImageLounge/plugins/cmake/Utils.cmake +@@ -139,7 +139,7 @@ macro(NMC_CREATE_TARGETS) + + elseif(UNIX) + set_target_properties(${PROJECT_NAME} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${NOMACS_BUILD_DIRECTORY}/plugins) +- install(TARGETS ${PROJECT_NAME} RUNTIME LIBRARY DESTINATION lib/nomacs-plugins) ++ install(TARGETS ${PROJECT_NAME} RUNTIME LIBRARY DESTINATION lib${LIB_SUFFIX}/nomacs-plugins) + set_property(TARGET ${PROJECT_NAME} PROPERTY VERSION ${NOMACS_VERSION_MAJOR}.${NOMACS_VERSION_MINOR}.${NOMACS_VERSION_PATCH}) + set_property(TARGET ${PROJECT_NAME} PROPERTY SOVERSION ${NOMACS_VERSION_MAJOR}) + endif(MSVC) diff --git a/media-gfx/nomacs/files/nomacs-3.16.224-libdir.patch b/media-gfx/nomacs/files/nomacs-3.16.224-libdir.patch new file mode 100644 index 000000000000..50b73028f303 --- /dev/null +++ b/media-gfx/nomacs/files/nomacs-3.16.224-libdir.patch @@ -0,0 +1,30 @@ +From c8f6c325c5f5170bb473c41ee716b781d37bdd41 Mon Sep 17 00:00:00 2001 +From: Markus Diem <diemmarkus@gmail.com> +Date: Mon, 27 Jul 2020 13:19:01 +0200 +Subject: [PATCH] fixes plugin path for fedora + +- thanks @tieugene +- beta version: 3.17 +--- + ImageLounge/src/DkCore/DkPluginManager.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +--- a/ImageLounge/src/DkCore/DkPluginManager.cpp ++++ b/ImageLounge/src/DkCore/DkPluginManager.cpp +@@ -62,6 +62,7 @@ + #include <QAction> + #include <QMenu> + #include <QJsonValue> ++#include <QLibraryInfo> + #pragma warning(pop) // no warnings from includes - end + + #ifdef QT_NO_DEBUG_OUTPUT +@@ -1309,7 +1310,7 @@ void DkPluginManager::createPluginsPath() { + #ifdef Q_OS_WIN + QDir pluginsDir = QCoreApplication::applicationDirPath() + "/plugins"; + #else +- QDir pluginsDir = QCoreApplication::applicationDirPath() + "/../lib/nomacs-plugins/"; ++ QDir pluginsDir = QLibraryInfo::location(QLibraryInfo::LibrariesPath) + "/nomacs-plugins/"; + #endif // Q_OS_WIN + + if (!pluginsDir.exists()) diff --git a/media-gfx/nomacs/nomacs-3.16.224-r6.ebuild b/media-gfx/nomacs/nomacs-3.16.224-r6.ebuild new file mode 100644 index 000000000000..0a8340d039e3 --- /dev/null +++ b/media-gfx/nomacs/nomacs-3.16.224-r6.ebuild @@ -0,0 +1,83 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +CMAKE_BUILD_TYPE="Release" # buildsys: what a mess +PLUGIN_PKG="${PN}-plugins-$(ver_cut 1-2)" +inherit cmake xdg + +DESCRIPTION="Qt-based image viewer" +HOMEPAGE="https://nomacs.org/" +SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz +plugins? ( https://github.com/${PN}/${PN}-plugins/archive/$(ver_cut 1-2).tar.gz -> ${PLUGIN_PKG}.tar.gz )" +CMAKE_USE_DIR="${S}/ImageLounge" + +LICENSE="GPL-3+" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~riscv ~x86 ~amd64-linux" +IUSE="+jpeg +opencv plugins raw +tiff zip" + +REQUIRED_USE=" + raw? ( opencv ) + tiff? ( opencv ) +" + +RDEPEND=" + dev-qt/qtconcurrent:5 + dev-qt/qtcore:5 + dev-qt/qtgui:5[jpeg?] + dev-qt/qtnetwork:5 + dev-qt/qtprintsupport:5 + dev-qt/qtsvg:5 + dev-qt/qtwidgets:5 + media-gfx/exiv2:= + opencv? ( >=media-libs/opencv-3.4:= ) + raw? ( media-libs/libraw:= ) + tiff? ( + dev-qt/qtimageformats:5 + media-libs/tiff:= + ) + zip? ( dev-libs/quazip:0=[qt5(+)] ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + dev-qt/linguist-tools:5 + virtual/pkgconfig +" + +DOCS=( src/changelog.txt ) + +PATCHES=( "${FILESDIR}"/${P}-libdir.patch ) + +src_prepare() { + if use plugins ; then + rmdir ImageLounge/plugins || die + mv -v ../${PLUGIN_PKG} ImageLounge/plugins || die + fi + + # from git master # reuse existing patches w/o paths adjusted + pushd "ImageLounge" > /dev/null || die + eapply "${FILESDIR}"/${P}-quazip1.patch + eapply "${FILESDIR}"/${P}-DkMath-ostream.patch + popd > /dev/null || die + + use plugins && eapply "${FILESDIR}"/${P}-libdir-plugins.patch + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DQT_QMAKE_EXECUTABLE=qmake5 # bug 847112 + -DENABLE_CODE_COV=OFF + -DUSE_SYSTEM_QUAZIP=ON + -DENABLE_TRANSLATIONS=ON + -DENABLE_OPENCV=$(usex opencv) + -DENABLE_PLUGINS=$(usex plugins) + -DENABLE_RAW=$(usex raw) + -DENABLE_TIFF=$(usex tiff) + -DENABLE_QUAZIP=$(usex zip) + ) + cmake_src_configure +} |