summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2021-12-19 23:58:55 +0000
committerSam James <sam@gentoo.org>2021-12-20 00:02:14 +0000
commite3fab0acfbb39f126224b70daf1927e3fe1404f8 (patch)
tree2c9f1cd42d48b1d5aeba9dde2391a6c731a4f50e /media-gfx
parentdev-util/gn: Stabilize 0.1943 arm64, #829636 (diff)
downloadgentoo-e3fab0acfbb39f126224b70daf1927e3fe1404f8.tar.gz
gentoo-e3fab0acfbb39f126224b70daf1927e3fe1404f8.tar.bz2
gentoo-e3fab0acfbb39f126224b70daf1927e3fe1404f8.zip
media-gfx/scrot: respect docdir
Closes: https://bugs.gentoo.org/828928 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'media-gfx')
-rw-r--r--media-gfx/scrot/files/scrot-1.7-fix-docdir.patch46
-rw-r--r--media-gfx/scrot/scrot-1.7-r2.ebuild (renamed from media-gfx/scrot/scrot-1.7-r1.ebuild)11
2 files changed, 55 insertions, 2 deletions
diff --git a/media-gfx/scrot/files/scrot-1.7-fix-docdir.patch b/media-gfx/scrot/files/scrot-1.7-fix-docdir.patch
new file mode 100644
index 000000000000..ebae595ac38f
--- /dev/null
+++ b/media-gfx/scrot/files/scrot-1.7-fix-docdir.patch
@@ -0,0 +1,46 @@
+https://github.com/resurrecting-open-source-projects/scrot/pull/175
+
+From: Sam James <sam@gentoo.org>
+Date: Sun, 19 Dec 2021 23:59:45 +0000
+Subject: [PATCH] build: respect docdir
+
+Before this patch with --docdir=/usr/share/doc/scrot-1.7-r1 (example downstream
+versioning for patches):
+```
+>>> /usr/share/doc/scrot-1.7-r1/
+>>> /usr/share/doc/scrot-1.7-r1/README.md.bz2
+>>> /usr/share/doc/scrot-1.7-r1/ChangeLog.bz2
+>>> /usr/share/doc/scrot-1.7-r1/AUTHORS.bz2
+>>> /usr/share/doc/scrot/
+>>> /usr/share/doc/scrot/scrot.png
+>>> /usr/share/doc/scrot/README.md.bz2
+>>> /usr/share/doc/scrot/ChangeLog.bz2
+>>> /usr/share/doc/scrot/AUTHORS.bz2
+```
+
+After:
+```
+>>> /usr/share/doc/scrot-1.7-r1/scrot.png
+>>> /usr/share/doc/scrot-1.7-r1/README.md.bz2
+>>> /usr/share/doc/scrot-1.7-r1/ChangeLog.bz2
+>>> /usr/share/doc/scrot-1.7-r1/AUTHORS.bz2
+```
+
+This avoids installing duplicate files & installs them to the
+same location but it's overridable by --docdir in ./configure which
+helps downstreams.
+
+Bug: https://bugs.gentoo.org/828928
+Signed-off-by: Sam James <sam@gentoo.org>
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -34,8 +34,7 @@ MAINTAINERCLEANFILES = Makefile.in
+
+ man_MANS = man/scrot.1
+
+-docs_DATA = README.md AUTHORS ChangeLog doc/scrot.png
+-docsdir = $(prefix)/share/doc/scrot
++doc_DATA = README.md AUTHORS ChangeLog doc/scrot.png
+
+ EXTRA_DIST = man/scrot.1 $(docs_DATA)
+
diff --git a/media-gfx/scrot/scrot-1.7-r1.ebuild b/media-gfx/scrot/scrot-1.7-r2.ebuild
index 80d7728667d6..3aa2ef8c7e06 100644
--- a/media-gfx/scrot/scrot-1.7-r1.ebuild
+++ b/media-gfx/scrot/scrot-1.7-r2.ebuild
@@ -3,7 +3,8 @@
EAPI=8
-inherit bash-completion-r1
+# Need autotools for docdir patch for now
+inherit autotools bash-completion-r1
DESCRIPTION="Screen capture utility using imlib2 library"
HOMEPAGE="https://github.com/resurrecting-open-source-projects/scrot"
@@ -45,10 +46,16 @@ DOCS=(
AUTHORS ChangeLog README.md
)
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.7-fix-docdir.patch
+)
+
src_prepare() {
default
- [[ ${PV} == *9999* ]] && eautoreconf
+ # Needed for 1.7 for the docdir patch
+ eautoreconf
+ #[[ ${PV} == *9999* ]] && eautoreconf
}
src_install() {