summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--user/scrot/APKBUILD6
-rw-r--r--user/scrot/docdir.patch51
2 files changed, 55 insertions, 2 deletions
diff --git a/user/scrot/APKBUILD b/user/scrot/APKBUILD
index d5316fe45..6e10c8a0c 100644
--- a/user/scrot/APKBUILD
+++ b/user/scrot/APKBUILD
@@ -10,9 +10,11 @@ arch="all"
license="MIT"
depends=""
makedepends="giblib-dev imlib2-dev libx11-dev libxfixes-dev libxcomposite-dev
- automake libtool autoconf autoconf-archive-dev sed"
+ automake libtool autoconf autoconf-archive-dev bsd-compat-headers
+ sed"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/resurrecting-open-source-projects/scrot/archive/$pkgver/$pkgname-$pkgver.tar.gz
+ docdir.patch
config.h
"
@@ -22,7 +24,6 @@ prepare() {
}
build() {
- sed -ie '2531d' configure
./configure \
--build=$CBUILD \
--host=$CHOST \
@@ -37,4 +38,5 @@ package() {
}
sha512sums="9f9a29b69e9c216bad7c6028fe0043b2729393a716dccc1389665cf1e9496a6f1d370b97a7c8432b31af7d69477b4fc1d41dffd4ca2a78a49bb98e908975612f scrot-1.7.tar.gz
+709d7dca5c6d8df7671a143b48817bd839d3ee8a97ed4128ce45345b2f91e0fe9e8b76f7d7233c2fe79bd1eafff8c3a0ed1272c65b4c583ebb0b3b5483bd34a9 docdir.patch
95429feb7c107c5adeadf33b5a3e3ff9dc4fb95f0d58f92c6a8de27d776a07256fa9f1825896d569eb32beb77300f46995dcafd1359f305d22861eb5748de84a config.h"
diff --git a/user/scrot/docdir.patch b/user/scrot/docdir.patch
new file mode 100644
index 000000000..b881802db
--- /dev/null
+++ b/user/scrot/docdir.patch
@@ -0,0 +1,51 @@
+From ee8121c65d1e6b84ef8a9fbc60a83734325b7fe2 Mon Sep 17 00:00:00 2001
+From: Sam James <sam@cmpct.info>
+Date: Wed, 5 Jan 2022 13:47:34 +0000
+Subject: [PATCH] autotools: 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
+---
+ Makefile.am | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 64439a8..7d2789c 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -34,10 +34,9 @@ MAINTAINERCLEANFILES = Makefile.in
+
+ man_MANS = man/scrot.1
+
+-docs_DATA = README.md AUTHORS ChangeLog doc/scrot.png
+-docsdir = $(prefix)/share/doc/scrot
++dist_doc_DATA = README.md AUTHORS ChangeLog doc/scrot.png
+
+-EXTRA_DIST = man/scrot.1 $(docs_DATA)
++EXTRA_DIST = $(man_MANS)
+
+ SUBDIRS = src
+