summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonny (tastytea) Gutbrod <gentoo@tastytea.de>2020-05-21 20:52:43 +0200
committerJoonas Niilola <juippis@gentoo.org>2020-06-16 09:02:51 +0300
commit28b1318d4915d68e7e081e5b96a46d73beccf062 (patch)
tree8782e8f44ed4212a6720b8e2e20ec7625a93088e /media-gfx/viewnior
parentapp-crypt/envchain: version bump to 1.0.1 (diff)
downloadgentoo-28b1318d4915d68e7e081e5b96a46d73beccf062.tar.gz
gentoo-28b1318d4915d68e7e081e5b96a46d73beccf062.tar.bz2
gentoo-28b1318d4915d68e7e081e5b96a46d73beccf062.zip
media-gfx/viewnior: Update metainfo location; Revbump.
- Use xdg for icon cache update. - EAPI 7. Closes: https://bugs.gentoo.org/724402 Signed-off-by: Ronny (tastytea) Gutbrod <gentoo@tastytea.de> Closes: https://github.com/gentoo/gentoo/pull/15905 Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'media-gfx/viewnior')
-rw-r--r--media-gfx/viewnior/files/viewnior-0.17-update_metadata_location.patch42
-rw-r--r--media-gfx/viewnior/viewnior-1.7-r2.ebuild52
2 files changed, 94 insertions, 0 deletions
diff --git a/media-gfx/viewnior/files/viewnior-0.17-update_metadata_location.patch b/media-gfx/viewnior/files/viewnior-0.17-update_metadata_location.patch
new file mode 100644
index 000000000000..492186059d91
--- /dev/null
+++ b/media-gfx/viewnior/files/viewnior-0.17-update_metadata_location.patch
@@ -0,0 +1,42 @@
+From f338c37881a860952aa10cc437bc72fa0b49a823 Mon Sep 17 00:00:00 2001
+From: tastytea <tastytea@tastytea.de>
+Date: Thu, 21 May 2020 20:07:45 +0200
+Subject: [PATCH] Rename appdata.xml to metainfo.xml and change install dir.
+
+The new name is used since AppStream 0.9.8 (2016-08-10) and the new
+location is used since AppStream 0.9.4 (2016-04-18).
+---
+ data/meson.build | 6 +++---
+ data/{viewnior.appdata.xml => viewnior.metainfo.xml} | 0
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+ rename data/{viewnior.appdata.xml => viewnior.metainfo.xml} (100%)
+
+diff --git a/data/meson.build b/data/meson.build
+index 55070fc..05d734e 100644
+--- a/data/meson.build
++++ b/data/meson.build
+@@ -17,8 +17,8 @@ install_data(
+ )
+
+ install_data(
+- 'viewnior.appdata.xml',
+- install_dir: join_paths(datadir, 'appdata')
++ 'viewnior.metainfo.xml',
++ install_dir: join_paths(datadir, 'metainfo')
+ )
+
+ desktop = i18n.merge_file(
+@@ -39,4 +39,4 @@ if desktop_file_validate.found()
+ desktop.full_path()
+ ]
+ )
+-endif
+\ No newline at end of file
++endif
+diff --git a/data/viewnior.appdata.xml b/data/viewnior.metainfo.xml
+similarity index 100%
+rename from data/viewnior.appdata.xml
+rename to data/viewnior.metainfo.xml
+--
+2.26.2
+
diff --git a/media-gfx/viewnior/viewnior-1.7-r2.ebuild b/media-gfx/viewnior/viewnior-1.7-r2.ebuild
new file mode 100644
index 000000000000..60e6b46a431e
--- /dev/null
+++ b/media-gfx/viewnior/viewnior-1.7-r2.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit meson xdg
+
+DESCRIPTION="Fast and simple image viewer"
+HOMEPAGE="
+ https://siyanpanayotov.com/project/viewnior/
+ https://github.com/hellosiyan/Viewnior
+"
+SRC_URI="https://github.com/hellosiyan/${PN^}/archive/${P}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="
+ dev-libs/glib:2
+ media-gfx/exiv2:0=
+ x11-libs/gtk+:2
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ dev-util/glib-utils
+ virtual/pkgconfig
+"
+
+S="${WORKDIR}/${PN^}-${P}"
+
+PATCHES=(
+ "${FILESDIR}/0.17-Replace-calls-to-getenv-with-g_getenv.patch"
+ "${FILESDIR}/viewnior-0.17-update_metadata_location.patch"
+)
+
+src_prepare() {
+ xdg_src_prepare
+
+ # That script would update icon cache and desktop database.
+ sed -i "s/meson.add_install_script('meson_post_install.py')//" meson.build \
+ || die 'Failed to remove post-install-script invocation from meson.build'
+ # Don't let meson compress the manpage.
+ sed -i "s/subdir('man')//" meson.build \
+ || die 'Failed to remove manpage compression from meson.build'
+}
+
+src_install() {
+ meson_src_install
+ doman man/viewnior.1
+}