summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess <joey@kitenet.net>2010-11-02 23:02:16 -0400
committerJoey Hess <joey@kitenet.net>2010-11-02 23:10:57 -0400
commit80031722bde4dbdcea47a2cbe979bfbd31adc61a (patch)
tree54491f2cf1385b621eb0ee73338d78fa36af9fea
parent76ef1cbd64829ee4a5156a5fc4b887bcba6b974f (diff)
Fix deprecated command list on translated debhelper(7) man pages. Closes: #601204
-rw-r--r--Makefile12
-rw-r--r--debian/changelog2
2 files changed, 11 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 3d47ea93..38f3c15d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,3 +1,9 @@
+# List of files of dh_* commands. Sorted for debhelper man page.
+COMMANDS=$(shell find . -maxdepth 1 -type f -perm +100 -name "dh_*" -printf "%f\n" | sort)
+
+# Find deprecated commands by looking at their synopsis.
+DEPRECATED=$(shell egrep -l '^dh_.* - .*deprecated' $(COMMANDS))
+
# This generates a list of synopses of debhelper commands, and substitutes
# it in to the #LIST# line on the man page fed to it on stdin. Must be passed
# parameters of all the executables or pod files to get the synopses from.
@@ -11,7 +17,7 @@ MAKEMANLIST=perl -e ' \
close IN; \
if ($$file=~m/=head1 .*?\n\n(.*?) - (.*?)\n\n/s) { \
my $$item="=item $$1(1)\n\n$$2\n\n"; \
- if ($$2!~/deprecated/) { \
+ if (" $(DEPRECATED) " !~ / $$1 /) { \
$$list.=$$item; \
} \
else { \
@@ -61,7 +67,7 @@ version:
debhelper.7: debhelper.pod
cat debhelper.pod | \
- $(MAKEMANLIST) `find . -maxdepth 1 -type f -perm +100 -name "dh_*" | sort` | \
+ $(MAKEMANLIST) $(COMMANDS) | \
$(POD2MAN) --name="debhelper" --section=7 > debhelper.7
clean:
@@ -76,7 +82,7 @@ install:
$(DESTDIR)/usr/share/debhelper/autoscripts \
$(DESTDIR)$(PERLLIBDIR)/Sequence \
$(DESTDIR)$(PERLLIBDIR)/Buildsystem
- install $(shell find -maxdepth 1 -mindepth 1 -name dh\* |grep -v \.1\$$) $(DESTDIR)/usr/bin
+ install dh $(COMMANDS) $(DESTDIR)/usr/bin
install -m 0644 autoscripts/* $(DESTDIR)/usr/share/debhelper/autoscripts
install -m 0644 Debian/Debhelper/*.pm $(DESTDIR)$(PERLLIBDIR)
install -m 0644 Debian/Debhelper/Sequence/*.pm $(DESTDIR)$(PERLLIBDIR)/Sequence
diff --git a/debian/changelog b/debian/changelog
index a0ae5e1f..04927d6a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -23,6 +23,8 @@ debhelper (8.1.0) UNRELEASED; urgency=low
* dh: Inhibit logging when an override target runs the overridden command,
to avoid unexpected behavior if the command succeeded but the overall
target fails. Closes: #601037
+ * Fix deprecated command list on translated debhelper(7) man pages.
+ Closes: #601204
-- Joey Hess <joeyh@debian.org> Sat, 07 Aug 2010 11:27:24 -0400