From: Eli Zaretskii Date: Fri, 25 Mar 2011 12:52:03 +0000 (+0200) Subject: Fix previous commit. X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~492^2 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f4d87671c6291c761da032f79910f36c7033020a;p=emacs.git 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 "", as lib/stdio.h cannot be left unused. --- diff --git a/config.bat b/config.bat index c90871de6ff..e480a4b9bc8 100644 --- a/config.bat +++ b/config.bat @@ -156,7 +156,7 @@ rm -f epaths.tmp rem Create "config.h" rm -f config.h2 config.tmp -sed -e '' config.in > config.tmp +sed -e '' ../autogen/config.in > config.tmp if "%X11%" == "" goto src4 sed -f ../msdos/sed2x.inp < ..\autogen\config.in > config.tmp :src4 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 * 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 + "", as lib/stdio.h cannot be left unused. 2011-02-26 Eli Zaretskii 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]*@// # /^NEXT_AS_FIRST_DIRECTIVE_GETOPT_H *=/s/@[^@\n]*@// # /^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]*@// /^NEXT_AS_FIRST_DIRECTIVE_STDDEF_H *=/s/@[^@\n]*@// /^NEXT_AS_FIRST_DIRECTIVE_STDINT_H *=/s/@[^@\n]*@// -/^NEXT_AS_FIRST_DIRECTIVE_STDIO_H *=/s/@[^@\n]*@// +/^NEXT_AS_FIRST_DIRECTIVE_STDIO_H *=/s/@[^@\n]*@// /^NEXT_AS_FIRST_DIRECTIVE_STDLIB_H *=/s/@[^@\n]*@// /^NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H *=/s!@[^@\n]*@!! /^NEXT_AS_FIRST_DIRECTIVE_TIME_H *=/s/@[^@\n]*@// /^NEXT_AS_FIRST_DIRECTIVE_UNISTD_H *=/s/@[^@\n]*@// /^NEXT_GETOPT_H *=/s/@[^@\n]*@// /^NEXT_STDDEF_H *=/s/@[^@\n]*@// -/^NEXT_STDIO_H *=/s/@[^@\n]*@// +/^NEXT_STDIO_H *=/s/@[^@\n]*@// /^NEXT_STDINT_H *=/s/@[^@\n]*@// /^NEXT_STDLIB_H *=/s/@[^@\n]*@// /^NEXT_SYS_STAT_H *=/s!@[^@\n]*@!! @@ -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"!