Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit bb874e3

Browse files
committed
Make INSTALL makefile rule more robust
With the previous rule, if pandoc was missing, a zero-length output file would be created without an error from make. To improve that, write the rule as two separate commands without a pipe. Reported-by: Tom Lane <tgl@sss.pgh.pa.us>
1 parent 7291733 commit bb874e3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

doc/src/sgml/Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,9 @@ ICONV = iconv
103103
PANDOC = pandoc
104104

105105
INSTALL: % : %.html
106-
$(PANDOC) $< -t plain | $(ICONV) -f utf8 -t us-ascii//TRANSLIT > $@
106+
$(PANDOC) -t plain -o $@.tmp $<
107+
$(ICONV) -f utf8 -t us-ascii//TRANSLIT $@.tmp > $@
108+
rm $@.tmp
107109

108110
INSTALL.html: %.html : stylesheet-text.xsl %.xml
109111
$(XMLLINT) --noout --valid $*.xml

0 commit comments

Comments
 (0)