aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2022-04-10 15:44:11 +0300
committerEli Zaretskii2022-04-10 15:44:11 +0300
commite8d2f40f41b09ec5e4b4eebe6441927e8d1dc434 (patch)
treeb86c821076391e231199fb3fd8a728cb7a206c26
parent338eda09d88d83d408c0bba1448b1c9eabad2d02 (diff)
downloademacs-e8d2f40f41b09ec5e4b4eebe6441927e8d1dc434.tar.gz
emacs-e8d2f40f41b09ec5e4b4eebe6441927e8d1dc434.zip
Clean up the MSDOS port
* src/msdos.h (tcdrain): Redirect to '_dos_commit'. (openat, fchmodat, futimens, utimensat): Add prototypes. * msdos/sed1v2.inp (MAKE_PDUMPER_FINGERPRINT): Fix indentation, so that Make won't consider this line a command. ($(etc)/DOC): Chdir back to ../src, since "make-docfile -d" leaves us in a wrong directory. * msdos/sedlibmk.inp (GL_GNULIB_GETRANDOM, GL_GNULIB_MEMMEM) (GL_GNULIB_SIGDESCR_NP): Define to 1, to get the prototypes from Gnulib headers.
-rw-r--r--msdos/sed1v2.inp8
-rw-r--r--msdos/sedlibmk.inp3
-rw-r--r--src/msdos.h9
3 files changed, 19 insertions, 1 deletions
diff --git a/msdos/sed1v2.inp b/msdos/sed1v2.inp
index e041e4e5b8d..a79bf2eb71c 100644
--- a/msdos/sed1v2.inp
+++ b/msdos/sed1v2.inp
@@ -179,6 +179,8 @@ s/ *@LIBXPM@//
179/^PAXCTL_dumped *=/s/=.*$/=/ 179/^PAXCTL_dumped *=/s/=.*$/=/
180/^PAXCTL_notdumped *=/s/=.*$/=/ 180/^PAXCTL_notdumped *=/s/=.*$/=/
181/^DUMPING *=/s/@DUMPING@/unexec/ 181/^DUMPING *=/s/@DUMPING@/unexec/
182/^[ \t]*MAKE_PDUMPER_FINGERPRINT = *$/c\
183MAKE_PDUMPER_FINGERPRINT =
182/^lisp\.mk:/,/^$/c\ 184/^lisp\.mk:/,/^$/c\
183lisp.mk: $(lispsource)/loadup.el\ 185lisp.mk: $(lispsource)/loadup.el\
184 @rm -f $@\ 186 @rm -f $@\
@@ -190,6 +192,10 @@ lisp.mk: $(lispsource)/loadup.el\
190 192
191/^ [ ]*\$(AM_V_at)\$(libsrc)\/make-docfile -d/s!make-docfile!make-docfile -o $(etc)/DOC! 193/^ [ ]*\$(AM_V_at)\$(libsrc)\/make-docfile -d/s!make-docfile!make-docfile -o $(etc)/DOC!
192/ > \$(etc)\/DOC *$/s/ >.*$// 194/ > \$(etc)\/DOC *$/s/ >.*$//
195/^\$(etc)\/DOC/,/^$/{
196 /^$/i\
197 cd ../src
198}
193/^ [ ]*\$(AM_V_GLOBALS)\$(libsrc)\/make-docfile.*>.*globals.tmp/s!make-docfile!make-docfile -o globals.tmp! 199/^ [ ]*\$(AM_V_GLOBALS)\$(libsrc)\/make-docfile.*>.*globals.tmp/s!make-docfile!make-docfile -o globals.tmp!
194/^ [ ]*\$(AM_V_GLOBALS)\$(libsrc)\/make-doc/s!>.*$!! 200/^ [ ]*\$(AM_V_GLOBALS)\$(libsrc)\/make-doc/s!>.*$!!
195/^\$(libsrc)\/make-docfile\$(EXEEXT): /i\ 201/^\$(libsrc)\/make-docfile\$(EXEEXT): /i\
@@ -255,4 +261,4 @@ s| -I\$(top_srcdir)/lib||
255s| -I\. -I\$(srcdir)| -I.| 261s| -I\. -I\$(srcdir)| -I.|
256/^ *test "X/d 262/^ *test "X/d
257/\$(CC) -o \$@.tmp/s/\$@.tmp/\$@/ 263/\$(CC) -o \$@.tmp/s/\$@.tmp/\$@/
258/mv \$@.tmp \$@/d \ No newline at end of file 264/mv \$@.tmp \$@/d
diff --git a/msdos/sedlibmk.inp b/msdos/sedlibmk.inp
index 59ebec9e756..e87cef5fff2 100644
--- a/msdos/sedlibmk.inp
+++ b/msdos/sedlibmk.inp
@@ -180,11 +180,14 @@ s/@PACKAGE@/emacs/
180/^GL_GNULIB_ENVIRON *=/s/@GL_GNULIB_ENVIRON@/1/ 180/^GL_GNULIB_ENVIRON *=/s/@GL_GNULIB_ENVIRON@/1/
181/^GL_GNULIB_FDATASYNC *=/s/@GL_GNULIB_FDATASYNC@/1/ 181/^GL_GNULIB_FDATASYNC *=/s/@GL_GNULIB_FDATASYNC@/1/
182/^GL_GNULIB_GETLOADAVG *=/s/@GL_GNULIB_GETLOADAVG@/1/ 182/^GL_GNULIB_GETLOADAVG *=/s/@GL_GNULIB_GETLOADAVG@/1/
183/^GL_GNULIB_GETRANDOM *=/s/@GL_GNULIB_GETRANDOM@/1/
183/^GL_GNULIB_UNISTD_H_GETOPT *=/s/@GL_GNULIB_UNISTD_H_GETOPT@/1/ 184/^GL_GNULIB_UNISTD_H_GETOPT *=/s/@GL_GNULIB_UNISTD_H_GETOPT@/1/
185/^GL_GNULIB_MEMMEM *=/s/@GL_GNULIB_MEMMEM@/1/
184/^GL_GNULIB_MEMRCHR *=/s/@GL_GNULIB_MEMRCHR@/1/ 186/^GL_GNULIB_MEMRCHR *=/s/@GL_GNULIB_MEMRCHR@/1/
185/^GL_GNULIB_MEMPCPY *=/s/@GL_GNULIB_MEMPCPY@/1/ 187/^GL_GNULIB_MEMPCPY *=/s/@GL_GNULIB_MEMPCPY@/1/
186/^GL_GNULIB_MKOSTEMP *=/s/@GL_GNULIB_MKOSTEMP@/1/ 188/^GL_GNULIB_MKOSTEMP *=/s/@GL_GNULIB_MKOSTEMP@/1/
187/^GL_GNULIB_MKTIME *=/s/@GL_GNULIB_MKTIME@/1/ 189/^GL_GNULIB_MKTIME *=/s/@GL_GNULIB_MKTIME@/1/
190/^GL_GNULIB_SIGDESCR_NP *=/s/@GL_GNULIB_SIGDESCR_NP@/1/
188/^GL_GNULIB_TIME_R *=/s/@GL_GNULIB_TIME_R@/1/ 191/^GL_GNULIB_TIME_R *=/s/@GL_GNULIB_TIME_R@/1/
189/^GL_GNULIB_TIMEGM *=/s/@GL_GNULIB_TIMEGM@/1/ 192/^GL_GNULIB_TIMEGM *=/s/@GL_GNULIB_TIMEGM@/1/
190/^GL_GNULIB_TIME_RZ *=/s/@GL_GNULIB_TIME_RZ@/1/ 193/^GL_GNULIB_TIME_RZ *=/s/@GL_GNULIB_TIME_RZ@/1/
diff --git a/src/msdos.h b/src/msdos.h
index 7e57c7c1102..24697bcf24b 100644
--- a/src/msdos.h
+++ b/src/msdos.h
@@ -22,6 +22,10 @@ along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. */
22#include <dpmi.h> 22#include <dpmi.h>
23 23
24#include "termhooks.h" /* struct terminal */ 24#include "termhooks.h" /* struct terminal */
25struct terminal;
26
27extern unsigned int _dos_commit(int);
28#define tcdrain(f) _dos_commit(f)
25 29
26int dos_ttraw (struct tty_display_info *); 30int dos_ttraw (struct tty_display_info *);
27int dos_ttcooked (void); 31int dos_ttcooked (void);
@@ -57,6 +61,11 @@ ssize_t readlinkat (int, const char *, char *, size_t);
57int fstatat (int, char const *, struct stat *, int); 61int fstatat (int, char const *, struct stat *, int);
58int unsetenv (const char *); 62int unsetenv (const char *);
59int faccessat (int, const char *, int, int); 63int faccessat (int, const char *, int, int);
64int openat (int, const char *, int, int);
65int fchmodat (int, const char *, mode_t, int);
66int futimens (int, const struct timespec[2]);
67int utimensat (int, const char *, const struct timespec[2], int);
68
60void msdos_fatal_signal (int); 69void msdos_fatal_signal (int);
61void syms_of_msdos (void); 70void syms_of_msdos (void);
62int pthread_sigmask (int, const sigset_t *, sigset_t *); 71int pthread_sigmask (int, const sigset_t *, sigset_t *);