]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
doc: post process html with non-GNU make programs
authorCollin Funk <collin.funk1@gmail.com>
Sun, 18 Jan 2026 05:23:15 +0000 (21:23 -0800)
committerCollin Funk <collin.funk1@gmail.com>
Sun, 18 Jan 2026 20:09:47 +0000 (12:09 -0800)
* .gitignore (/build-aux/makeinfo-wrapper.sh):
* Makefile.am (EXTRA_DIST): Remove build-aux/makeinfo-wrapper.sh.
* build-aux/makeinfo-wrapper.sh.in: New file, renamed from
build-aux/makeinfo-wrapper.sh and modified to use @MAKEINFO@ instead of
makeinfo.
* cfg.mk (MAKEINFO): Remove variable.
* configure.ac: Add build-aux/makeinfo-wrapper.sh as a configure file.
* doc/local.mk (MAKEINFO): Define to
$(abs_top_builddir)/build-aux/makeinfo-wrapper.sh.
(AM_MAKEINFOFLAGS): Move over some values from the previous MAKEINFO
definition.

.gitignore
Makefile.am
build-aux/makeinfo-wrapper.sh.in [moved from build-aux/makeinfo-wrapper.sh with 97% similarity]
cfg.mk
configure.ac
doc/local.mk

index 756f2d87409708650885157daf88af6b91b6895d..b6a576d5623f5e670aac42a57541f74d6303db80 100644 (file)
@@ -29,6 +29,7 @@
 /build-aux/config.sub
 /build-aux/depcomp
 /build-aux/install-sh
+/build-aux/makeinfo-wrapper.sh
 /build-aux/mdate-sh
 /build-aux/missing
 /build-aux/snippet/
index 5a6ebc04069c153283285887bdccf29250612851..2e9c4ed55278885efd17bed27d23970c0ba88f4e 100644 (file)
@@ -32,7 +32,6 @@ EXTRA_DIST =                          \
   bootstrap.conf                       \
   build-aux/gen-lists-of-programs.sh   \
   build-aux/gen-single-binary.sh       \
-  build-aux/makeinfo-wrapper.sh                \
   cfg.mk                               \
   dist-check.mk                                \
   maint.mk                             \
similarity index 97%
rename from build-aux/makeinfo-wrapper.sh
rename to build-aux/makeinfo-wrapper.sh.in
index 41b7ad45d7dcd8dfd6ad24be1e031443c03ea285..6acea2f19e849f722391319c68b6ed57aa5f55da 100755 (executable)
@@ -3,7 +3,7 @@
 # only on lines containing "option", corresponding to our @optAnchor macro.
 # Note texi uses "-" in anchors for spaces, hence why it escapes - with _002d.
 
-makeinfo "$@" || exit
+@MAKEINFO@ "$@" || exit
 
 process_html()
 {
diff --git a/cfg.mk b/cfg.mk
index 7d8b5013d795fd71edc072bdf8b00138592ef027..1dfa4352a9516bffc304d9647541a35401ceca14 100644 (file)
--- a/cfg.mk
+++ b/cfg.mk
@@ -17,8 +17,6 @@
 # Used in maint.mk's web-manual rule
 manual_title = Core GNU utilities
 
-# html post processing
-export MAKEINFO = $(abs_top_srcdir)/build-aux/makeinfo-wrapper.sh
 # Don't create node redirection files for each anchor
 gendocs_options_ = --common --no-node-files
 
index bdd6e4038eaa33ddec0ce8f6edeeec6b88a14799..3c03ddd03641f5c030cd74e4f9af6a681993fbd6 100644 (file)
@@ -904,4 +904,6 @@ AC_CONFIG_FILES(
   po/Makefile.in
   gnulib-tests/Makefile
   )
+AC_CONFIG_FILES([build-aux/makeinfo-wrapper.sh],
+                [chmod +x build-aux/makeinfo-wrapper.sh])
 AC_OUTPUT
index 04ce909e9b0726325f987a59dcdb1aa5421c382f..129def7cdb474a634b7d2cc50501910aadb66369 100644 (file)
@@ -25,9 +25,11 @@ doc_coreutils_TEXINFOS = \
   doc/fdl.texi \
   doc/sort-version.texi
 
+MAKEINFO = $(abs_top_builddir)/build-aux/makeinfo-wrapper.sh
+
 # The customization variable CHECK_NORMAL_MENU_STRUCTURE is necessary with
 # makeinfo versions ≥ 6.8.
-MAKEINFO = @MAKEINFO@ -c CHECK_NORMAL_MENU_STRUCTURE=1
+AM_MAKEINFOFLAGS = -c CHECK_NORMAL_MENU_STRUCTURE=1
 
 # The following is necessary if the package name is 8 characters or longer.
 # If the info documentation would be split into 10 or more separate files,
@@ -37,7 +39,7 @@ MAKEINFO = @MAKEINFO@ -c CHECK_NORMAL_MENU_STRUCTURE=1
 # Otherwise, it would also generate files with names like <package>.info-[123],
 # and those names all map to one 14-byte name (<package>.info-) on some crufty
 # old systems.
-AM_MAKEINFOFLAGS = --no-split
+AM_MAKEINFOFLAGS += --no-split
 
 doc/constants.texi: $(top_srcdir)/src/tail.c $(top_srcdir)/src/shred.c
        $(AM_V_GEN)LC_ALL=C; export LC_ALL; \