summaryrefslogblamecommitdiff
path: root/user/scrot/docdir.patch
blob: b881802dbbe842b6a60cde7c40c87f251e2980f2 (plain) (tree)


















































                                                                               
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