summaryrefslogtreecommitdiff
path: root/msdos
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2011-03-25 14:52:03 +0200
committerEli Zaretskii <eliz@gnu.org>2011-03-25 14:52:03 +0200
commitf4d87671c6291c761da032f79910f36c7033020a (patch)
tree7269f8d01ae2c7b1500ec5b0427122dcb811a324 /msdos
parent07da4b3c924abe8cc95e88ce2f19daeebd8bba21 (diff)
downloademacs-f4d87671c6291c761da032f79910f36c7033020a.tar.gz
Fix previous commit.
config.bat: Use autogen/config.in in one more place. msdos/sedlibmk.inp (GNULIB_PRINTF, GNULIB_PRINTF_POSIX): Add missing variables. (MKDIR_P): Fix replacement command. (NEXT_AS_FIRST_DIRECTIVE_STDIO_H, NEXT_STDIO_H): Edit to "<stdio.h>", as lib/stdio.h cannot be left unused.
Diffstat (limited to 'msdos')
-rw-r--r--msdos/ChangeLog6
-rw-r--r--msdos/sedlibmk.inp32
2 files changed, 29 insertions, 9 deletions
diff --git a/msdos/ChangeLog b/msdos/ChangeLog
index ce51a753741..f8215584f1e 100644
--- a/msdos/ChangeLog
+++ b/msdos/ChangeLog
@@ -1,6 +1,12 @@
2011-03-25 Eli Zaretskii <eliz@gnu.org>
* sedlibmk.inp: Adapt to addition of the gnulib stdio module.
+ Add a description of what needs to be done when a new gnulib
+ module is added.
+ (GNULIB_PRINTF, GNULIB_PRINTF_POSIX): Add missing variables.
+ (MKDIR_P): Fix replacement command.
+ (NEXT_AS_FIRST_DIRECTIVE_STDIO_H, NEXT_STDIO_H): Edit to
+ "<stdio.h>", as lib/stdio.h cannot be left unused.
2011-02-26 Eli Zaretskii <eliz@gnu.org>
diff --git a/msdos/sedlibmk.inp b/msdos/sedlibmk.inp
index 8a261400189..d7af3681ef9 100644
--- a/msdos/sedlibmk.inp
+++ b/msdos/sedlibmk.inp
@@ -28,23 +28,28 @@
#
# /^REPLACE_CALLOC *=/s/@REPLACE_CALLOC@/0/
#
-# . If it's a header, edit the corresponding variable to either an
-# empty value or to the name of the header. Examples:
+# . If the module is a header or adds headers, edit the corresponding
+# variable to either an empty value or to the name of the header.
+# Examples:
#
# /^STDINT_H *=/s/@[^@\n]*@/stdint.h/ -- stdint.h is needed
# /^STDDEF_H *=/s/@[^@\n]*@// -- stddef.h is not needed
#
# . Also edit the NEXT_foo and NEXT_AS_FIRST_DIRECTIVE_foo_H variable
-# as appropriately: to an empty value if the DJGPP system header
-# should not be included after the gnulib one, or if the gnulib one
-# is not needed; and to the corresponding DJGPP header name
-# otherwise. Examples:
+# as appropriately: to an empty value if the gnulib header is not
+# used, and to the corresponding DJGPP header name otherwise.
+# Examples:
#
# /^NEXT_STDDEF_H *=/s/@[^@\n]*@//
# /^NEXT_STDINT_H *=/s/@[^@\n]*@/<stdint.h>/
# /^NEXT_AS_FIRST_DIRECTIVE_GETOPT_H *=/s/@[^@\n]*@/<getopt.h>/
# /^NEXT_AS_FIRST_DIRECTIVE_STDDEF_H *=/s/@[^@\n]*@//
#
+# . Note that some gnulib headers cannot be left unused: those for
+# which there's no corresponding foo_H variable in
+# autogen/Makefile.in (example: stdio.h). For these the "not
+# needed" path is not applicable.
+#
# . If the header is needed, edit all the variables it uses as
# appropriate. In general, if DJGPP has the corresponding feature,
# the value of the corresponding HAVE_foo should be set to what
@@ -78,6 +83,13 @@
# s/'\; \\ *$/' >> $@-t/
# }
#
+# The following Awk script is useful for editing portions of
+# autogen/Makefile.in into Sed commands that define the corresponding
+# variables to zero (which is what is required in the absolute
+# majority of cases):
+#
+# { printf "/^%s *=/s/%s/0/\n",$1,$3}
+#
# ----------------------------------------------------------------------
# Replace @..@ constants.
/^\# @configure_input@/s!@configure_input@!lib/Makefile. Generated from Makefile.in by config.bat!
@@ -195,6 +207,8 @@ am__cd = cd
/^GNULIB_PIPE2 *=/s/@GNULIB_PIPE2@/0/
/^GNULIB_POPEN *=/s/@GNULIB_POPEN@/0/
/^GNULIB_PREAD *=/s/@GNULIB_PREAD@/0/
+/^GNULIB_PRINTF *=/s/@GNULIB_PRINTF@/0/
+/^GNULIB_PRINTF_POSIX *=/s/@GNULIB_PRINTF_POSIX@/0/
/^GNULIB_PTSNAME *=/s/@GNULIB_PTSNAME@/0/
/^GNULIB_PUTC *=/s/@GNULIB_PUTC@/0/
/^GNULIB_PUTCHAR *=/s/@GNULIB_PUTCHAR@/0/
@@ -366,14 +380,14 @@ am__cd = cd
/^NEXT_AS_FIRST_DIRECTIVE_GETOPT_H *=/s/@[^@\n]*@/<getopt.h>/
/^NEXT_AS_FIRST_DIRECTIVE_STDDEF_H *=/s/@[^@\n]*@//
/^NEXT_AS_FIRST_DIRECTIVE_STDINT_H *=/s/@[^@\n]*@/<stdint.h>/
-/^NEXT_AS_FIRST_DIRECTIVE_STDIO_H *=/s/@[^@\n]*@//
+/^NEXT_AS_FIRST_DIRECTIVE_STDIO_H *=/s/@[^@\n]*@/<stdio.h>/
/^NEXT_AS_FIRST_DIRECTIVE_STDLIB_H *=/s/@[^@\n]*@/<stdlib.h>/
/^NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H *=/s!@[^@\n]*@!<sys/stat.h>!
/^NEXT_AS_FIRST_DIRECTIVE_TIME_H *=/s/@[^@\n]*@/<time.h>/
/^NEXT_AS_FIRST_DIRECTIVE_UNISTD_H *=/s/@[^@\n]*@/<unistd.h>/
/^NEXT_GETOPT_H *=/s/@[^@\n]*@/<getopt.h>/
/^NEXT_STDDEF_H *=/s/@[^@\n]*@//
-/^NEXT_STDIO_H *=/s/@[^@\n]*@//
+/^NEXT_STDIO_H *=/s/@[^@\n]*@/<stdio.h>/
/^NEXT_STDINT_H *=/s/@[^@\n]*@/<stdint.h>/
/^NEXT_STDLIB_H *=/s/@[^@\n]*@/<stdlib.h>/
/^NEXT_SYS_STAT_H *=/s!@[^@\n]*@!<sys/stat.h>!
@@ -526,4 +540,4 @@ s/\.in-h\; *\\$/.in-h >> $@-t/
/^unistd\.h:/,/^ [ ]*mv /{
s/'\; \\ *$/' >> $@-t/
}
-s!\$(MKDIR_P)[ ][ ]*sys!command.com /c "if not exist sys\stat.h md sys"!
+s!\$(MKDIR_P)[ ][ ]*sys!command.com /c "if not exist sys\\stat.h md sys"!