summaryrefslogtreecommitdiff
path: root/Build/source/texk/kpathsea/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Build/source/texk/kpathsea/Makefile.am')
-rw-r--r--Build/source/texk/kpathsea/Makefile.am17
1 files changed, 9 insertions, 8 deletions
diff --git a/Build/source/texk/kpathsea/Makefile.am b/Build/source/texk/kpathsea/Makefile.am
index e1184d7e646..0ff3b8c5419 100644
--- a/Build/source/texk/kpathsea/Makefile.am
+++ b/Build/source/texk/kpathsea/Makefile.am
@@ -159,8 +159,8 @@ kpseinclude_HEADERS = \
## First null out comments and leading/trailing whitespace, then remove
## lines that define invalid C identifiers, then remove blank lines and
-## lines that define lowercase values (those are never path values). Each
-## line remaining looks like
+## lines that define lowercase values (those are never path values).
+## Each line remaining looks like
## <name> = <value>
## (but = and surrounding spaces are optional, hence can't remove all spaces).
## Change this to #ifndef DEFAULT_name@#define DEFAULT_name "value"@#endif,
@@ -181,18 +181,19 @@ kpseinclude_HEADERS = \
##
## The definition of DEFAULT_TEXMF (and other variables)
## that winds up in the final paths.h will not be used.
-#
+##
## We don't want to rewrite paths.h when we have only changed comments
## in texmf.cnf that have no effect on paths.h, since that would cause
## almost everything to be rebuilt.
-#
+##
## We also replace all semicolons with colons in the paths.
-## The path-splitting code should be changed to understand both.
-#
+## (The path-splitting code should be changed to understand both.)
+##
paths.h: stamp-paths
-stamp-paths: texmf.cnf
+stamp-paths: texmf.cnf bsnl.awk
echo "/* paths.h: Generated from texmf.cnf. */" >paths.tmp
- sed -e 's/%.*//' -e 's/^[ ]*//' -e 's/[ ]*$$//' $< \
+ awk -f $(srcdir)/bsnl.awk texmf.cnf \
+ | sed -e 's/%.*//' -e 's/^[ ]*//' -e 's/[ ]*$$//' \
| grep '^[ ]*[A-Z0-9_]*[ =]' \
| sed '/^$$/d' \
| sed 's/^\([^ =]*\)[ ]*=*[ ]*\(.*\)/#ifndef DEFAULT_\1%#define DEFAULT_\1 "\2"%#endif/' \