;; configure.ac with sed, rather than duplicating the information.
(set-version-in-file root "msdos/sed2v2.inp" version
(rx (and bol "/^#undef " (1+ not-newline)
- "define VERSION" (1+ space) "\""
+ "define PACKAGE_VERSION" (1+ space) "\""
(submatch (1+ (in "0-9."))))))
;; Major version only.
(when (string-match "\\([0-9]\\{2,\\}\\)" version)
update config.h2 config.h >nul\r
rm -f config.tmp config.h2\r
\r
-rem On my system dir.h gets in the way. It's a VMS file so who cares.\r
-if exist dir.h ren dir.h vmsdir.h\r
-\r
rem Create "makefile" from "makefile.in".\r
rm -f Makefile makefile.tmp\r
copy Makefile.in+deps.mk makefile.tmp\r
sed -e "/^LIBXML2_CFLAGS *=/s|=|= -I/dev/env/DJDIR/include/libxml2|" <makefile.tmp >Makefile\r
rm -f makefile.tmp\r
:src7\r
+Rem Create .d files for new files in src/\r
+If Not Exist deps\stamp mkdir deps\r
+for %%f in (*.c) do @call ..\msdos\depfiles.bat %%f\r
+echo deps-stamp > deps\stamp\r
cd ..\r
rem ----------------------------------------------------------------------\r
Echo Configuring the library source directory...\r
If Exist build-aux\snippet\c++defs.h update build-aux/snippet/c++defs.h build-aux/snippet/cxxdefs.h\r
cd lib\r
Rem Rename files like djtar on plain DOS filesystem would.\r
+If Exist c++defs.h update c++defs.h cxxdefs.h\r
If Exist alloca.in.h update alloca.in.h alloca.in-h\r
If Exist byteswap.in.h update byteswap.in.h byteswap.in-h\r
If Exist dirent.in.h update dirent.in.h dirent.in-h\r
If Exist execinfo.in.h update execinfo.in.h execinfo.in-h\r
If Exist fcntl.in.h update fcntl.in.h fcntl.in-h\r
If Exist getopt.in.h update getopt.in.h getopt.in-h\r
+If Exist getopt-cdefs.in.h update getopt-cdefs.in.h getopt-cdefs.in-h\r
If Exist inttypes.in.h update inttypes.in.h inttypes.in-h\r
-If Exist stdarg.in.h update stdarg.in.h stdarg.in-h\r
-If Exist stdalign.in.h update stdalign.in.h stdalign.in-h\r
-If Exist stdbool.in.h update stdbool.in.h stdbool.in-h\r
+If Exist limits.in.h update limits.in.h limits.in-h\r
If Exist signal.in.h update signal.in.h signal.in-h\r
-If Exist stdalign.in.h update stdalign.in.h stdalign.in-h\r
+If Exist signal.in.h update signal.in.h signal.in-h\r
+If Exist stdalign.in.h update stdalign.in.h stdalign.in-h\r
If Exist stddef.in.h update stddef.in.h stddef.in-h\r
If Exist stdint.in.h update stdint.in.h stdint.in-h\r
If Exist stdio.in.h update stdio.in.h stdio.in-h\r
If Exist string.in.h update string.in.h string.in-h\r
If Exist sys_select.in.h update sys_select.in.h sys_select.in-h\r
If Exist sys_stat.in.h update sys_stat.in.h sys_stat.in-h\r
-If Exist sys_types.in.h update sys_types.in.h sys_types.in-h\r
If Exist sys_time.in.h update sys_time.in.h sys_time.in-h\r
+If Exist sys_types.in.h update sys_types.in.h sys_types.in-h\r
If Exist time.in.h update time.in.h time.in-h\r
If Exist unistd.in.h update unistd.in.h unistd.in-h\r
+If Exist gnulib.mk.in update gnulib.mk.in gnulib.mk-in\r
Rem Only repository has the msdos/autogen directory\r
If Exist Makefile.in sed -f ../msdos/sedlibcf.inp < Makefile.in > makefile.tmp\r
If Exist ..\msdos\autogen\Makefile.in sed -f ../msdos/sedlibcf.inp < ..\msdos\autogen\Makefile.in > makefile.tmp\r
sed -f ../msdos/sedlibmk.inp < makefile.tmp > Makefile\r
rm -f makefile.tmp\r
-Rem Create .Po files for new files in lib/\r
+sed -f ../msdos/sedlibcf.inp < gnulib.mk-in > gnulib.tmp\r
+sed -f ../msdos/sedlibmk.inp < gnulib.tmp > gnulib.mk\r
+rm -f gnulib.tmp\r
+Rem Create .d files for new files in lib/\r
If Not Exist deps\stamp mkdir deps\r
for %%f in (*.c) do @call ..\msdos\depfiles.bat %%f\r
echo deps-stamp > deps\stamp\r
\r
rem ----------------------------------------------------------------------\r
\r
-echo %1 | sed -e "s,\(.*\)\.c,@if not exist deps\\\1.Po echo # dummy > deps\\\1.Po," > tdepfile.bat\r
+echo %1 | sed -e "s,\(.*\)\.c,@if not exist deps\\\1.d echo # dummy > deps\\\1.d," > tdepfile.bat\r
call tdepfile\r
del tdepfile.bat\r
/^IMAGEMAGICK_CFLAGS *=/s/@IMAGEMAGICK_CFLAGS@//
/^LIBXML2_LIBS *=/s/@LIBXML2_LIBS@//
/^LIBXML2_CFLAGS *=/s/@LIBXML2_CFLAGS@//
+/^GETADDRINFO_A_LIBS *=/s/@GETADDRINFO_A_LIBS@//
+/^LIBLCMS2 *=/s/@LIBLCMS2@//
/^WIDGET_OBJ *=/s/@WIDGET_OBJ@//
/^XWIDGETS_OBJ *=/s/@XWIDGETS_OBJ@//
/^WEBKIT_LIBS *=/s/@WEBKIT_LIBS@//
/^CAIRO_CFLAGS *=/s/@CAIRO_CFLAGS@//
/^XFIXES_LIBS *=/s/@XFIXES_LIBS@//
/^XFIXES_CFLAGS *=/s/@XFIXES_CFLAGS@//
+/^XDBE_LIBS *=/s/@XDBE_LIBS@//
+/^XDBE_CFLAGS *=/s/@XDBE_CFLAGS@//
/^CYGWIN_OBJ *=/s/@CYGWIN_OBJ@//
/^WINDOW_SYSTEM_OBJ *=/s/@WINDOW_SYSTEM_OBJ@//
/^MSDOS_OBJ *=/s/= */= dosfns.o msdos.o w16select.o/
/^NS_OBJ *=/s/@NS_OBJ@//
/^NS_OBJC_OBJ *=/s/@NS_OBJC_OBJ@//
/^GNU_OBJC_CFLAGS*=/s/=.*$/=/
-/^LIBRESOLV *=/s/@LIBRESOLV@//
/^LIBMODULES *=/s/@LIBMODULES@//
/^MODULES_OBJ *=/s/@MODULES_OBJ@//
/^LIBSELINUX_LIBS *=/s/@LIBSELINUX_LIBS@//
+/^LIBSYSTEMD_LIBS *=/s/@LIBSYSTEMD_LIBS@//
+/^LIBSYSTEMD_CFLAGS *=/s/@LIBSYSTEMD_CFLAGS@//
/^LIB_CLOCK_GETTIME *=/s/@[^@\n]*@//g
/^LIB_TIMER_TIME *=/s/@[^@\n]*@//g
/^LIB_EXECINFO *=/s/@[^@\n]*@//g
/^XRANDR_CFLAGS *=/s/@XRANDR_CFLAGS@//
/^XINERAMA_LIBS *=/s/@XINERAMA_LIBS@//
/^XINERAMA_CFLAGS *=/s/@XINERAMA_CFLAGS@//
+/^HYBRID_MALLOC *=/s/@HYBRID_MALLOC@//
/^GMALLOC_OBJ *=/s/@GMALLOC_OBJ@/gmalloc.o/
/^VMLIMIT_OBJ *=/s/@VMLIMIT_OBJ@/vm-limit.o/
/^FIRSTFILE_OBJ *=/s/@FIRSTFILE_OBJ@//
/^PRE_ALLOC_OBJ *=/s/@PRE_ALLOC_OBJ@/lastfile.o/
/^POST_ALLOC_OBJ *=/s/@POST_ALLOC_OBJ@/$(vmlimitobj)/
/^UNEXEC_OBJ *=/s/@UNEXEC_OBJ@/unexcoff.o/
+/^BUILD_DETAILS *=/s/@BUILD_DETAILS@//
/^CANNOT_DUMP *=/s/@CANNOT_DUMP@/no/
-/^DEPFLAGS *=/s/@DEPFLAGS@//
-/^MKDEPDIR *=/s/@MKDEPDIR@//
/^W32_OBJ *=/s/@W32_OBJ@//
/^W32_LIBS *=/s/@W32_LIBS@//
/^version *=/s/@[^@\n]*@//
/^ [ ]*\$(AM_V_GLOBALS)\$(libsrc)\/make-doc/s!>.*$!!
/^\$(libsrc)\/make-docfile\$(EXEEXT): /i\
cd ../src
-/^\$(leimdir)\/leim-list.el: /s/bootstrap-emacs\$(EXEEXT)/b-emacs$(EXEEXT)/
/^ if test -f/,/^ fi$/c\
command.com /c if exist .gdbinit rm -f _gdbinit
/^ *ifneq (\$(PAXCTL_notdumped),)/,/^ *endif/d
/^ *ifneq (\$(PAXCTL_dumped),)/,/^ *endif/d
/^ *ln /s/ln /cp /
-/^ *\$(SETFATTR_if_present) -n/d
/^ fi/d
/^ *\$(RUN_TEMACS) /i\
stubedit temacs.exe minstack=1024k
/^ *LC_ALL=C \$(RUN_TEMACS)/i\
stubedit temacs.exe minstack=1024k
/^ *LC_ALL=C.*\$(RUN_TEMACS)/s/LC_ALL=C/set &;/
-/-batch -l loadup/a\
+/-batch .* -l loadup/a\
stubify emacs\
stubedit emacs.exe minstack=3072k
s/ @true *$/ @rem/
/^ [^ ]*echo[ ][ ]*timestamp/s/echo /djecho /
/^ .*djecho timestamp/a\
@rm -f globals.tmp
-/^ *@\$(MKDEPDIR) *$/d
/^ mv \.\/\.gdbinit/d
/^ if test -f/,/^ fi$/c\
command.com /c if exist .gdbinit rm -f _gdbinit
/^ @: /d
/^ -\{0,1\} *ln /s/ln /cp /
/^[ ]touch /s/touch/djecho $@ >/
-s/@YMF_PASS_LDFLAGS@/flags/
-s/@PRE_EDIT_LDFLAGS@//
-s/@POST_EDIT_LDFLAGS@//
s/bootstrap-emacs/b-emacs/
-s/bootstrap-temacs/b-temacs/
-s/bootstrap-doc/b-doc/
/rm -f bootstrap-emacs/s/b-emacs/b-emacs b-emacs.exe/
s/echo.*buildobj.lst/dj&/
/ --load loadup bootstrap/a\
}
# Remove or replace dependencies we cannot have
/^\.PRECIOUS: /s!\.\./config.status !!
-/^\.\.\/config.status: /d
+/^\.\.\/config.status: /,/^ /d
/^Makefile: /s!\.\./config.status !!
-/^\$(top_srcdir)\/aclocal\.m4 /,/^doc\.o:/c\
-\
-doc.o: buildobj.h
# Make the GCC command line fit one screen line
/^[ ][ ]*\$(GNUSTEP_CFLAGS)/d
-/^[ ][ ]*\$(GCONF_CFLAGS)/d
/^[ ][ ]*\$(LIBGNUTLS_CFLAGS)/d
-s/\$(LIBOTF_CFLAGS) \$(M17N_FLT_CFLAGS) \$(DEPFLAGS) //
+/^[ ][ ]*\$(LIBSYSTEMD_CFLAGS)/d
+/^[ ][ ]*\$(XRANDR_CFLAGS)/d
+/^[ ][ ]*\$(WEBKIT_CFLAGS)/d
+/^[ ][ ]*\$(SETTINGS_CFLAGS)/d
+s/\$(LIBOTF_CFLAGS) \$(M17N_FLT_CFLAGS) //
s/ \$(C_SWITCH_X_SITE)//
s/ \$(DBUS_CFLAGS)//
s/ \$(PNG_CFLAGS) //
-s/ \$(XINERAMA_CFLAGS)//
-s/ \$(XFIXES_CFLAGS)//
-s/ \$(FREETYPE_CFLAGS)//
-s/ \$(FONTCONFIG_CFLAGS)//
s| -I\$(srcdir)/\.\./lib||
s| -I\$(top_srcdir)/lib||
-# Add our local inttypes.h to prerequisites where needed
-/^lread\.o:/s|lread\.c|& ../msdos/inttypes.h|
+s| -I\. -I\$(srcdir)| -I.|
/^ *test "X/d
/^#undef HAVE_STRNCASECMP *$/s/^.*$/#define HAVE_STRNCASECMP 1/
/^#undef HAVE_STRUCT_TM_TM_ZONE *$/s/^.*$/#define HAVE_STRUCT_TM_TM_ZONE 1/
/^#undef HAVE_SYNC *$/s/^.*$/#define HAVE_SYNC 1/
+/^#undef HAVE___BUILTIN_FRAME_ADDRESS *$/s/^.*$/#define HAVE___BUILTIN_FRAME_ADDRESS 1/
/^#undef HAVE___BUILTIN_UNWIND_INIT *$/s/^.*$/#define HAVE___BUILTIN_UNWIND_INIT 1/
/^#undef HAVE_MENUS *$/s/^.*$/#define HAVE_MENUS 1/
/^#undef DATA_START/s/^.*$/#define DATA_START (\&etext + 1)/
/^#undef PACKAGE_NAME/s/^.*$/#define PACKAGE_NAME ""/
/^#undef PACKAGE_STRING/s/^.*$/#define PACKAGE_STRING ""/
/^#undef PACKAGE_TARNAME/s/^.*$/#define PACKAGE_TARNAME ""/
-/^#undef PACKAGE_VERSION/s/^.*$/#define PACKAGE_VERSION VERSION/
-/^#undef PENDING_OUTPUT_COUNT/s/^.*$/#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_ptr - (FILE)->_base)/
-/^#undef VERSION/s/^.*$/#define VERSION "26.0.90"/
+/^#undef PACKAGE_VERSION/s/^.*$/#define PACKAGE_VERSION "26.0.90"/
/^#undef SYSTEM_TYPE/s/^.*$/#define SYSTEM_TYPE "ms-dos"/
/^#undef HAVE_DECL_GETENV/s/^.*$/#define HAVE_DECL_GETENV 1/
/^#undef SYS_SIGLIST_DECLARED/s/^.*$/#define SYS_SIGLIST_DECLARED 1/
/^#undef IS_DIRECTORY_SEP *$/s,^.*$,#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\'),
/^#undef IS_DEVICE_SEP *$/s/^.*$/#define IS_DEVICE_SEP(_c_) ((_c_) == ':')/
/^#undef IS_ANY_SEP *$/s/^.*$/#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP (_c_))/
+/^#undef NEED_MKTIME_INTERNAL *$/s/^.*$/#define NEED_MKTIME_INTERNAL 1/
+/^#undef NEED_MKTIME_WORKING *$/s/^.*$/#define NEED_MKTIME_WORKING 1/
/^#undef INTERNAL_TERMINAL *$/s,^.*$,#define INTERNAL_TERMINAL "pc|bios|IBM PC with color display::co#80:li#25:Co#16:pa#256:km:ms:cm=<CM>:cl=<CL>:ce=<CE>::se=</SO>:so=<SO>:us=<UL>:ue=</UL>:md=<BD>:mh=<DIM>:mb=<BL>:mr=<RV>:me=<NV>::AB=<BG %d>:AF=<FG %d>:op=<DefC>:",
/^#undef NULL_DEVICE *$/s/^.*$/#define NULL_DEVICE "nul"/
/^#undef SEPCHAR *$/s/^.*$/#define SEPCHAR '\;'/
s/^#undef EMACS_CONFIGURATION *$/#define EMACS_CONFIGURATION "i386-pc-msdosdjgpp"/
s/^#undef EMACS_CONFIG_OPTIONS *$/#define EMACS_CONFIG_OPTIONS "msdos"/
s/^#undef EMACS_CONFIG_FEATURES *$/#define EMACS_CONFIG_FEATURES ""/
+s|^#undef FLEXIBLE_ARRAY_MEMBER *$|#define FLEXIBLE_ARRAY_MEMBER /**/|
s/^#undef PROTOTYPES *$/#define PROTOTYPES 1/
s/^#undef POINTER_TYPE *$/#define POINTER_TYPE void/
/^#undef HAVE_INTTYPES_H/c\
#undef HAVE_STDINT_H\
#endif
s/^#undef HAVE_C_VARARRAYS *$/#define HAVE_C_VARARRAYS 1/
+s/^#undef HAVE_DECL_ALIGNED_ALLOC *$/#define HAVE_DECL_ALIGNED_ALLOC 0/
+s/^#undef HAVE_DECL_CLEARERR_UNLOCKED *$/#define HAVE_DECL_CLEARERR_UNLOCKED 0/
+s/^#undef HAVE_DECL_FEOF_UNLOCKED *$/#define HAVE_DECL_FEOF_UNLOCKED 0/
+s/^#undef HAVE_DECL_FERROR_UNLOCKED *$/#define HAVE_DECL_FERROR_UNLOCKED 0/
+s/^#undef HAVE_DECL_FFLUSH_UNLOCKED *$/#define HAVE_DECL_FFLUSH_UNLOCKED 0/
+s/^#undef HAVE_DECL_FGETS_UNLOCKED *$/#define HAVE_DECL_FGETS_UNLOCKED 0/
+s/^#undef HAVE_DECL_FPUTC_UNLOCKED *$/#define HAVE_DECL_FPUTC_UNLOCKED 0/
+s/^#undef HAVE_DECL_FPUTS_UNLOCKED *$/#define HAVE_DECL_FPUTS_UNLOCKED 0/
+s/^#undef HAVE_DECL_FREAD_UNLOCKED *$/#define HAVE_DECL_FREAD_UNLOCKED 0/
+s/^#undef HAVE_DECL_FWRITE_UNLOCKED *$/#define HAVE_DECL_FWRITE_UNLOCKED 0/
+s/^#undef HAVE_DECL_GETCHAR_UNLOCKED *$/#define HAVE_DECL_GETCHAR_UNLOCKED 0/
+s/^#undef HAVE_DECL_GETC_UNLOCKED *$/#define HAVE_DECL_GETC_UNLOCKED 0/
+s/^#undef HAVE_DECL_PUTCHAR_UNLOCKED *$/#define HAVE_DECL_PUTCHAR_UNLOCKED 0/
+s/^#undef HAVE_DECL_PUTC_UNLOCKED *$/#define HAVE_DECL_PUTC_UNLOCKED 0/
s/^#undef HAVE_DECL_STRTOLL *$/#define HAVE_DECL_STRTOLL 1/
-s/^#undef HAVE_DECL_STRTOULL *$/#define HAVE_DECL_STRTOULL 1/
s/^#undef HAVE_DECL_STRTOIMAX *$/#define HAVE_DECL_STRTOIMAX 1/
-s/^#undef HAVE_DECL_STRTOUMAX *$/#define HAVE_DECL_STRTOUMAX 1/
s/^#undef HAVE_STRTOLL *$/#define HAVE_STRTOLL 1/
s/^#undef HAVE_STRTOULL *$/#define HAVE_STRTOULL 1/
+/^#undef HAVE_STRUCT_DIRENT_D_TYPE *$/c\
+#if __DJGPP__ + (__DJGPP_MINOR__ >= 5) >= 3\
+#define HAVE_STRUCT_DIRENT_D_TYPE 1/\
+#else\
+#undef HAVE_STRUCT_DIRENT_D_TYPE\
+#endif
+s/^#undef HAVE_STRUCT_ATTRIBUTE_ALIGNED *$/#define HAVE_STRUCT_ATTRIBUTE_ALIGNED 1/
s/^#undef HAVE_PUTENV *$/#define HAVE_PUTENV 1/
/^#undef HAVE_SIGSET_T *$/s/^.*$/#define HAVE_SIGSET_T 1/
/^#undef HAVE_SNPRINTF/c\
#include <sys/types.h>\
extern int snprintf (char *__restrict, size_t, const char *__restrict, ...);\
#endif
-s/^#undef PENDING_OUTPUT_N_BYTES *$/#define PENDING_OUTPUT_N_BYTES fp->_ptr - fp->_base/
+/^#include <conf_post.h>/i\
+/* From libc/file.h, needed by lib/fpending.c. */\
+#define _IOERR 000200
# Comment out any remaining undef directives, because some of them
# might be defined in sys/config.h we include at the top of config.h.
/^archlibdir *=/s!=.*$!=/emacs/bin!
/^bindir *=/s!=.*$!=/emacs/bin!
/^libdir *=/s!=.*$!=/emacs/bin!
-/^srcdir=/s!srcdir=@srcdir@!srcdir := $(subst \\,/,$(shell command.com /c cd))!
+/^srcdir=/s!srcdir=@srcdir@!srcdir := $(CURDIR)!
/^VPATH *=/s!=.*$!=.!
/^BLESSMAIL_TARGET *=/s!@BLESSMAIL_TARGET@!need-blessmail!
/^KRB4LIB *=/s/@[^@\n]*@//g
/^C_SWITCH_MACHINE *=/s/@C_SWITCH_MACHINE@//
/^WARN_CFLAGS *=/s/@WARN_CFLAGS@//
/^WERROR_CFLAGS *=/s/@WERROR_CFLAGS@//
-/^UPDATE_MANIFEST *=/s/@UPDATE_MANIFEST@//
/^PROFILING_CFLAGS *=/s/@PROFILING_CFLAGS@//
/^AM_DEFAULT_VERBOSITY *=/s/@AM_DEFAULT_VERBOSITY@/1/
/^[Aa][Mm]_/s/@AM_V@/$(V)/
/^GETOPT_H *=/s!@GETOPT_H@!getopt.h!
/^GETOPTOBJS *=/s!@GETOPTOBJS@!getopt.o getopt1.o!
/^INSTALLABLES/s/emacsclient[^ ]* *//
-/^UTILITIES *=/,/^$/{
- s/movemail[^ ]* *//
-}
#
# Checklist to add a new gnulib module:
#
-# . If the module includes source files that need to be compiled, and
-# does not appear in the am_libgnu_a_OBJECTS list, add the
-# corresponding .o file names to the list that gets assigned to the
-# gl_LIBOBJS variable.
-#
-# . If a module appears in am_libgnu_a_OBJECTS that is not required
-# for the MSDOS build, edit it out by adding an appropriate command
-# to the set that edits the am_libgnu_a_OBJECTS block.
+# . If a module appears in gnulib.mk.in that is not required for the
+# MSDOS build, disable its building by setting the corresponding
+# OMIT_GNULIB_MODULE_foo variable to true.
#
# . If the module defines functions that need to replace DJGPP
# functions, edit the appropriate REPLACE_foo variables to 1:
# as above should be placed before that catchall rule (search for
# "REPLACE_" below).
#
-# . 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:
+# . If the module generates a header from a .in.h file, 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
#
# . Some of the headers are generated conditionally, and the
-# corresponding recipes are guarded by @GL_GENERATE_xxxx_H_TRUE@
-# and @GL_GENERATE_xxxx_H_FALSE@. Depending on whether DJGPP uses
-# the corresponding header, these should be edited either to
-# nothing (thus exposing the recipe) or to #, which comments the
-# recipe away. Example:
+# corresponding recipes are guarded by
+# ifneq (,$(GL_GENERATE_xxxx_H))
+# Depending on whether DJGPP uses the corresponding header, these
+# should be edited either to 1 (thus exposing the recipe) or
+# to notyhing, which makes Make bypass the recipe away. Example:
#
-# s/^@GL_GENERATE_STDBOOL_H_TRUE@/\#/
-# s/^@GL_GENERATE_STDBOOL_H_FALSE@//
+# s/^@GL_GENERATE_STDBOOL_H@/1/
+# s/^@GL_GENERATE_STDINT_H@//
#
# . Also edit the NEXT_foo_H and NEXT_AS_FIRST_DIRECTIVE_foo_H
# variables as appropriately: to an empty value if the gnulib
#
# . Note that some gnulib headers cannot be left unused: those for
# which there's no corresponding foo_H variable in
-# msdos/autogen/Makefile.in (example: stdio.h). For these the "not
+# lib/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
/^@SET_MAKE@$/s/@SET_MAKE@//
/^VPATH *=/s/@[^@\n]*@/./
s/@PACKAGE@/emacs/
-/^am__cd *=/c\
-am__cd = cd
/^@BUILDING_FOR_WINDOWSNT_TRUE@/s/@[^@\n]*@/#/
/^@BUILDING_FOR_WINDOWSNT_FALSE@/s/@[^@\n]*@//
/^ALLOCA *=/s/@[^@\n]*@//
/^AR *=/s/@[^@\n]*@/ar/
/^ARFLAGS *=/s/@[^@\n]*@/cru/
/^AWK *=/s/@[^@\n]*@/gawk/
+/^AUTO_DEPEND *=/s/@AUTO_DEPEND@/yes/
/^CANNOT_DUMP *=/s/@[^@\n]*@/no/
/^CC *=/s/@[^@\n]*@/gcc -std=gnu99/
/^CPP *=/s/@[^@\n]*@/gcc -e/
/^C_SWITCH_X_SITE *=/s/@C_SWITCH_X_SITE@//
/^PROFILING_CFLAGS *=/s/@PROFILING_CFLAGS@//
/^GNULIB_WARN_CFLAGS *=/s/@GNULIB_WARN_CFLAGS@//
+/^HYBRID_MALLOC *=/s/@HYBRID_MALLOC@//
/^WARN_CFLAGS *=/s/@WARN_CFLAGS@//
/^WERROR_CFLAGS *=/s/@WERROR_CFLAGS@//
/^DEFS *=/s/@[^@\n]*@//
/^GNULIB_MKOSTEMP *=/s/@GNULIB_MKOSTEMP@/1/
/^GNULIB_MKTIME *=/s/@GNULIB_MKTIME@/1/
/^GNULIB_TIME_R *=/s/@GNULIB_TIME_R@/1/
+/^GNULIB_TIMEGM *=/s/@GNULIB_TIMEGM@/1/
/^GNULIB_TIME_RZ *=/s/@GNULIB_TIME_RZ@/1/
/^GNULIB_UNSETENV *=/s/@GNULIB_UNSETENV@/1/
/^GNULIB_[^ =]* *= *@/s/@[^@\n]*@/0/
/^HAVE_SYS_PARAM_H *=/s/@HAVE_SYS_PARAM_H@/1/
/^HAVE_SYS_TIME_H *=/s/@HAVE_SYS_TIME_H@/1/
/^HAVE_SYS_TYPES_H *=/s/@HAVE_SYS_TYPES_H@/1/
+/^HAVE_TIMEGM *=/s/@HAVE_TIMEGM@/0/
/^HAVE_TYPE_VOLATILE_SIG_ATOMIC_T *=/s/@HAVE_TYPE_VOLATILE_SIG_ATOMIC_T@/1/
/^HAVE_UNISTD_H *=/s/@HAVE_UNISTD_H@/1/
/^HAVE_UNSIGNED_LONG_LONG_INT *=/s/@HAVE_UNSIGNED_LONG_LONG_INT@/1/
/^NEXT_AS_FIRST_DIRECTIVE_ERRNO_H *=/s/@[^@\n]*@//
/^NEXT_AS_FIRST_DIRECTIVE_FCNTL_H *=/s/@[^@\n]*@/<fcntl.h>/
/^NEXT_AS_FIRST_DIRECTIVE_GETOPT_H *=/s/@[^@\n]*@/<getopt.h>/
+/^NEXT_AS_FIRST_DIRECTIVE_LIMITS_H *=/s/@[^@\n]*@/<limits.h>/
/^NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H *=/s/@[^@\n]*@/<signal.h>/
/^NEXT_AS_FIRST_DIRECTIVE_STDDEF_H *=/s/@[^@\n]*@/<stddef.h>/
/^NEXT_AS_FIRST_DIRECTIVE_STDINT_H *=/s/@[^@\n]*@/<stdint.h>/
/^NEXT_ERRNO_H *=/s/@[^@\n]*@//
/^NEXT_FCNTL_H *=/s/@[^@\n]*@/<fcntl.h>/
/^NEXT_GETOPT_H *=/s/@[^@\n]*@/<getopt.h>/
+/^NEXT_LIMITS_H *=/s/@[^@\n]*@/<limits.h>/
/^NEXT_SIGNAL_H *=/s/@[^@\n]*@/<signal.h>/
/^NEXT_STDDEF_H *=/s/@[^@\n]*@/<stddef.h>/
/^NEXT_STDIO_H *=/s/@[^@\n]*@/<stdio.h>/
/^DIRENT_H *=/s/@[^@\n]*@//
/^ERRNO_H *=/s/@[^@\n]*@//
/^EXECINFO_H *=/s/@[^@\n]*@/execinfo.h/
+/^GETOPT_CDEFS_H *=/s/@[^@\n]*@/getopt-cdefs.h/
+/^LIMITS_H *=/s/@[^@\n]*@/limits.h/
/^STDALIGN_H *=/s/@[^@\n]*@/stdalign.h/
/^STDDEF_H *=/s/@[^@\n]*@/stddef.h/
/^STDINT_H *=/s/@[^@\n]*@/stdint.h/
/^WINT_T_SUFFIX *=/s/@WINT_T_SUFFIX@//
/^WINDOWS_64_BIT_OFF_T *=/s/@WINDOWS_64_BIT_OFF_T@/0/
/^WINDOWS_64_BIT_ST_SIZE *=/s/@WINDOWS_64_BIT_ST_SIZE@/0/
+/^WINDOWS_STAT_INODES *=/s/@WINDOWS_STAT_INODES@/0/
+/^WINDOWS_STAT_TIMESPEC *=/s/@WINDOWS_STAT_TIMESPEC@/0/
# Tailor lists of files to what we need
/am__append_[1-9][0-9]* *=.*gettext\.h/s/@[^@\n]*@/\#/
/am__append_2 *=.*verify\.h/s/@[^@\n]*@//
/^top_builddir *=/s/@[^@\n]*@/../
s/@PRAGMA_SYSTEM_HEADER@/\#pragma GCC system_header/
s/@PRAGMA_COLUMNS@//
+/^SYSTEM_TYPE *=/s/@SYSTEM_TYPE@/msdos/
+/^ifneq (\$(SYSTEM_TYPE),windows-nt)/,/^endif/d
+/^DEPDIR *=/a\
+AUTO_DEPEND = yes
#
# Delete the recipes we don't want to get in our way.
-/^\$(srcdir)\/Makefile\.in:/,/^[ ][ ]*\$(AUTOMAKE)/d
-/^Makefile:/,/^[ ][ ]*esac/d
-/^\$(top_srcdir)\/configure:/,/^\$(am__aclocal_m4_deps):/d
-/^\$(top_builddir)\/config.status:/,/^$/d
+/^\.\.\/config.status:/,/^Makefile:/c\
+Makefile: $(srcdir)/Makefile.in
#
# Remove the dependencies on $(top_builddir)/config.status
-s/ $(top_builddir)\/config.status//
+s/ \.\.\/config.status//
+s/ \$(top_builddir)\/config.status//
#
# Fix the include-dependency lines
s/^@AMDEP_TRUE@//
s/^ -*test -z.*|| rm/ -rm/
s/@echo /@djecho /
#
-# Fix the recipes for header files
-s/^@GL_GENERATE_ALLOCA_H_TRUE@//
-s/^@GL_GENERATE_ALLOCA_H_FALSE@/\#/
-s/^@GL_GENERATE_BYTESWAP_H_TRUE@//
-s/^@GL_GENERATE_BYTESWAP_H_FALSE@/\#/
-s/^@GL_GENERATE_ERRNO_H_TRUE@/\#/
-s/^@GL_GENERATE_ERRNO_H_FALSE@//
-s/^@GL_GENERATE_EXECINFO_H_TRUE@//
-s/^@GL_GENERATE_EXECINFO_H_FALSE@/\#/
-s/^@GL_GENERATE_STDALIGN_H_TRUE@//
-s/^@GL_GENERATE_STDALIGN_H_FALSE@/\#/
-s/^@GL_GENERATE_STDDEF_H_TRUE@//
-s/^@GL_GENERATE_STDDEF_H_FALSE@/\#/
-s/^@GL_GENERATE_STDINT_H_TRUE@//
-s/^@GL_GENERATE_STDINT_H_FALSE@/\#/
-s/^@GL_GENERATE_STDALIGN_H_TRUE@//
-s/^@GL_GENERATE_STDALIGN_H_FALSE@/\#/
+# Determine which headers to generate
+s/= @GL_GENERATE_ALLOCA_H@/= 1/
+s/= @GL_GENERATE_BYTESWAP_H@/= 1/
+s/= @GL_GENERATE_EXECINFO_H@/= 1/
+s/= @GL_GENERATE_STDALIGN_H@/= 1/
+s/= @GL_GENERATE_STDDEF_H@/= 1/
+s/= @GL_GENERATE_STDINT_H@/= 1/
+s/= @GL_GENERATE_LIMITS_H@/= 1/
+s/= @GL_GENERATE_ERRNO_H@/= /
+s/= @GL_GENERATE_LIMITS_H@/= /
+#
+# Determine which modules to build and which to omit
+/^noinst_LIBRARIES /a\
+OMIT_GNULIB_MODULE_acl-permissions = true\
+OMIT_GNULIB_MODULE_allocator = true\
+OMIT_GNULIB_MODULE_at-internal = true\
+OMIT_GNULIB_MODULE_careadlinkat = true\
+OMIT_GNULIB_MODULE_cloexec = true\
+OMIT_GNULIB_MODULE_dirent = true\
+OMIT_GNULIB_MODULE_dirfd = true\
+OMIT_GNULIB_MODULE_dup2 = true\
+OMIT_GNULIB_MODULE_errno = true\
+OMIT_GNULIB_MODULE_euidaccess = true\
+OMIT_GNULIB_MODULE_faccessat = true\
+OMIT_GNULIB_MODULE_fcntl = true\
+OMIT_GNULIB_MODULE_fdopendir = true\
+OMIT_GNULIB_MODULE_fstatat = true\
+OMIT_GNULIB_MODULE_fsync = true\
+OMIT_GNULIB_MODULE_getdtablesize = true\
+OMIT_GNULIB_MODULE_getgroups = true\
+OMIT_GNULIB_MODULE_gettimeofday = true\
+OMIT_GNULIB_MODULE_group-member = true\
+OMIT_GNULIB_MODULE_inttypes-incomplete = true\
+OMIT_GNULIB_MODULE_localtime-buffer = true\
+OMIT_GNULIB_MODULE_lstat = true\
+OMIT_GNULIB_MODULE_open = true\
+OMIT_GNULIB_MODULE_pipe2 = true\
+OMIT_GNULIB_MODULE_pselect = true\
+OMIT_GNULIB_MODULE_putenv = true\
+OMIT_GNULIB_MODULE_qcopy-acl = true\
+OMIT_GNULIB_MODULE_readlink = true\
+OMIT_GNULIB_MODULE_readlinkat = true\
+OMIT_GNULIB_MODULE_strtoimax = true\
+OMIT_GNULIB_MODULE_strtoll = true\
+OMIT_GNULIB_MODULE_symlink = true\
+OMIT_GNULIB_MODULE_sys_select = true\
+OMIT_GNULIB_MODULE_sys_time = true
/^arg-nonnull\.h:/,/^[ ][ ]*mv /c\
arg-nonnull.h: $(top_srcdir)/build-aux/snippet/arg-nonnull.h\
sed -n -e '/GL_ARG_NONNULL/,$$p' < $(top_srcdir)/build-aux/snippet/arg-nonnull.h > $@
s/^ [ ]*{ echo \(.*\); \\/ djecho \1 > $@-t/
s/^ [ ]*{ echo \(.*\) && \\/ djecho \1 > $@-t/
s/^ [ ]*cat \(.*\); \\/ sed -e '' \1 >> $@-t/
+s/^ sed -e/ sed -e/
s/ \&\& \\ *$//
s/\.in-h\; *\\$/.in-h >> $@-t/
/^ [ ]*} /d
/^top_srcdir *=/s|@top_srcdir@|./..|
/^EXEEXT *=/s/@EXEEXT@/.exe/
/^XARGS_LIMIT *=/s|@XARGS_LIMIT@||
+/^FIND_DELETE *=/s/@FIND_DELETE@/-delete/
/^AM_DEFAULT_VERBOSITY *=/s/@AM_DEFAULT_VERBOSITY@/1/
/^[Aa][Mm]_/s/@AM_V@/$(V)/
/^[Aa][Mm]_/s/@AM_DEFAULT_V@/$(AM_DEFAULT_VERBOSITY)/
#include <stdbool.h>
-#if defined DOS_NT && !defined DEFER_MS_W32_H
+#if defined WINDOWSNT && !defined DEFER_MS_W32_H
# include <ms-w32.h>
#endif
int
faccessat (int dirfd, const char * path, int mode, int flags)
{
+ char fullname[MAXPATHLEN];
+
/* We silently ignore FLAGS. */
flags = flags;
#include <dpmi.h>
+#include "termhooks.h" /* struct terminal */
+
int dos_ttraw (struct tty_display_info *);
int dos_ttcooked (void);
int dos_get_saved_screen (char **, int *, int *);
/* Constants. */
#define EINPROGRESS 112
+#define ENOTSUP ENOSYS
/* Gnulib sets O_CLOEXEC to O_NOINHERIT, which gets in the way when we
need to redirect standard handles for subprocesses using temporary
files created by mkostemp, see callproc.c. */
#include <netinet/in.h>
#include <arpa/inet.h>
+#endif /* subprocesses */
+
#ifdef HAVE_SETRLIMIT
# include <sys/resource.h>
static struct rlimit nofile_limit;
#endif
+#ifdef subprocesses
+
/* Are local (unix) sockets supported? */
#if defined (HAVE_SYS_UN_H)
#if !defined (AF_LOCAL) && defined (AF_UNIX)
#else /* not subprocesses */
+/* This is referenced in thread.c:run_thread (which is never actually
+ called, since threads are not enabled for this configuration. */
+void
+update_processes_for_thread_death (Lisp_Object dying_thread)
+{
+}
+
/* Defined in msdos.c. */
extern int sys_select (int, fd_set *, fd_set *, fd_set *,
struct timespec *, void *);
pthread_sigmask (SIG_SETMASK, oldset, 0);
}
+#endif /* !MSDOS */
+
/* Block SIGINT. */
void
block_interrupt_signal (sigset_t *oldset)
pthread_sigmask (SIG_SETMASK, oldset, 0);
}
-#endif /* !MSDOS */
\f
/* Saving and restoring the process group of Emacs's terminal. */
#endif
#ifdef MSDOS
+/* The above #define for 'select' gets in the way because sysselect.h
+ is included in thread.h, which is included everywhere, and 'select'
+ declared in DJGPP system headers has a signature incompatible with
+ 'pselect', which we emulate in msdos.c. */
+#undef select
#define pselect sys_select
#endif
{
/* Restore the previous situation. */
all_threads = all_threads->next_thread;
+#ifdef THREADS_ENABLED
error ("Could not start a new thread");
+#else
+ error ("Concurrency is not supported in this configuration");
+#endif
}
/* FIXME: race here where new thread might not be filled in? */
#include <sys/socket.h>
#endif
+#ifdef MSDOS
+#include <signal.h> /* sigset_t */
+#endif
+
#include "sysselect.h" /* FIXME */
#include "systime.h" /* FIXME */
#include "systhread.h"