GraphicsMagick: doc/GNUmakefile: Use GNU make rules to produce t...

GraphicsMagick Commits <[email protected]>
Newsgroups gmane.comp.video.graphicsmagick.cvs
Message-ID <mailman.46743.1640970516.2008.graphicsmagick-commit@lists.sourceforge.net>
changeset 764d46677eca in /hg/GraphicsMagick
details: http://hg.GraphicsMagick.org/hg/GraphicsMagick?cmd=changeset;node=764d46677eca
summary: doc/GNUmakefile: Use GNU make rules to produce the full imdoc list

diffstat:

 ChangeLog       |   7 +++++++
 doc/GNUmakefile |  27 ++++++++++++++-------------
 2 files changed, 21 insertions(+), 13 deletions(-)

diffs (80 lines):

diff -r 9dd4673e32d9 -r 764d46677eca ChangeLog
--- a/ChangeLog	Thu Dec 30 19:27:37 2021 -0600
+++ b/ChangeLog	Fri Dec 31 11:08:22 2021 -0600
@@ -1,3 +1,10 @@
+2021-12-31  Bob Friesenhahn  <[email protected]>
+
+        * doc/GNUmakefile: Use GNU make rules to produce the full imdoc
+        list for man, html, and tex, rather than relying on a shell
+        wildcard expression, since the order produced by the shell
+        wildcard expression is indeterminate.
+
 2021-12-30  Bob Friesenhahn  <[email protected]>
 
         * www/index.rst: Document that
diff -r 9dd4673e32d9 -r 764d46677eca doc/GNUmakefile
--- a/doc/GNUmakefile	Thu Dec 30 19:27:37 2021 -0600
+++ b/doc/GNUmakefile	Fri Dec 31 11:08:22 2021 -0600
@@ -1,4 +1,4 @@
-# Copyright (C) 2003-2013 GraphicsMagick Group
+# Copyright (C) 2003-2021 GraphicsMagick Group
 #
 # This program is covered by multiple licenses, which are described in
 # Copyright.txt. You should have received a copy of Copyright.txt with this
@@ -8,7 +8,9 @@
 # Written by Bob Friesenhahn based on previous work by Glenn Randers-Pehrson
 #
 
+# This list also determines the order of the manual page
 UTILITIES = \
+	GraphicsMagick \
 	animate \
 	batch \
 	benchmark \
@@ -22,12 +24,11 @@
 	mogrify \
 	montage \
 	time \
-	version \
-	GraphicsMagick
+	version
 
 UTILSUBDIR       = expanded/$(UTILITY)
 UTILBASE         = $(UTILITY)
-UTILSUBWILDCARD  = expanded/*
+UTILSUBWILDCARD  = $(addprefix expanded/, $(UTILITIES))
 INSTALLWWW       = ../www
 INSTALLUTILITIES = ../utilities
 GMSUBDIR=Gm
@@ -104,22 +105,22 @@
 $(INSTALLUTILITIES)/gm.1: gm.1
 	cp -p $< $@
 
-$(GMSUBDIR)/man.imdoc: targets-man
-	@if test ! -d $(GMSUBDIR); then mkdir -p $(GMSUBDIR); fi
+$(GMSUBDIR):
+	mkdir -p $(GMSUBDIR)
+
+$(GMSUBDIR)/man.imdoc: targets-man $(GMSUBDIR)
 	-rm -f $@ [email protected]
-	cat $(UTILSUBWILDCARD)/man.imdoc > [email protected] && \
+	cat $(addsuffix /man.imdoc, $(UTILSUBWILDCARD)) > [email protected] && \
 	mv [email protected] $@
 
-$(GMSUBDIR)/html.imdoc: targets-html
-	@if test ! -d $(GMSUBDIR); then mkdir -p $(GMSUBDIR); fi
+$(GMSUBDIR)/html.imdoc: targets-html $(GMSUBDIR)
 	-rm -f $@ [email protected]
-	cat $(UTILSUBWILDCARD)/html.imdoc > [email protected] && \
+	cat $(addsuffix /html.imdoc, $(UTILSUBWILDCARD)) > [email protected] && \
 	mv [email protected] $@
 
-$(GMSUBDIR)/tex.imdoc: targets-tex
-	@if test ! -d $(GMSUBDIR); then mkdir -p $(GMSUBDIR); fi
+$(GMSUBDIR)/tex.imdoc: targets-tex $(GMSUBDIR)
 	-rm -f $@ [email protected]
-	cat $(UTILSUBWILDCARD)/tex.imdoc > [email protected] && \
+	cat $(addsuffix /tex.imdoc, $(UTILSUBWILDCARD)) > [email protected] && \
 	mv [email protected] $@
 
 #
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.