* doc/local.mk (html-local): Add html files to prerequisites so they are
generated before 'sed' is invoked. Also interate over the already
populated $(HTMLS) to be more general (to multiple html files),
and more portable (to non GNU make).
# Post-process generated HTML to clean up anchor IDs
_sed_anchor_cleanup = \
-e '/id=.*_002doption/ { s/id="\([^"]*\)_002doption/id="\1/g; s/_002d/-/g; }'
-html-local:
- $(AM_V_GEN)htmlfile=$(info_TEXINFOS:.texi=.html); \
- sed $(_sed_anchor_cleanup) $$htmlfile > $$htmlfile-t \
- && mv $$htmlfile-t $$htmlfile
+html-local: $(HTMLS)
+ $(AM_V_GEN)for htmlfile in $(HTMLS); do \
+ sed $(_sed_anchor_cleanup) $$htmlfile > $$htmlfile-t \
+ && mv $$htmlfile-t $$htmlfile; done
.PHONY: html-local