]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix the MS-DOS build
authorPo Lu <luangruo@yahoo.com>
Wed, 6 Jul 2022 06:09:51 +0000 (14:09 +0800)
committerPo Lu <luangruo@yahoo.com>
Wed, 6 Jul 2022 06:09:51 +0000 (14:09 +0800)
* msdos/sedlibmk.inp: Define GL_GNULIB_RAWMEMCHR.
* src/process.c (Fsignal_names): Disable on MS-DOS and use
SIGNUM_BOUND, which is always provided by gnulib.

msdos/sedlibmk.inp
src/process.c

index 302fefe19f035ec79d177ec7d6a44e8bfdc48d5e..9847e710c0ff2d21f544c0a93393c46e599ef704 100644 (file)
@@ -192,6 +192,9 @@ s/@PACKAGE@/emacs/
 /^GL_GNULIB_TIMEGM *=/s/@GL_GNULIB_TIMEGM@/1/
 /^GL_GNULIB_TIME_RZ *=/s/@GL_GNULIB_TIME_RZ@/1/
 /^GL_GNULIB_UNSETENV *=/s/@GL_GNULIB_UNSETENV@/1/
+# Apparently without this `rawmemchr' isn't declared, so
+# we get warnings building canonicalize-lgpl.o
+/^GL_GNULIB_RAWMEMCHR *=/s/@GL_GNULIB_RAWMEMCHR@/1/
 /^GL_GNULIB_[^ =]* *= *@/s/@[^@\n]*@/0/
 /^GL_GSETTINGS_CFLAGS *=/s/@[^@\n]*@//
 /^GL_GSETTINGS_LIBS *=/s/@[^@\n]*@//
index af402c8edb3f5a4221cbae065423ef1e4bc50781..d6d51b26e111bca66a4d20bf4166df310a92c9af 100644 (file)
@@ -8321,14 +8321,21 @@ DEFUN ("signal-names", Fsignal_names, Ssignal_names, 0, 0, 0,
        doc: /* Return a list of known signal names on this system.  */)
   (void)
 {
+#ifndef MSDOS
+  int i;
   char name[SIG2STR_MAX];
   Lisp_Object names = Qnil;
-  for (int i = 0; i < 256; ++i)
+
+  for (i = 0; i <= SIGNUM_BOUND; ++i)
     {
       if (!sig2str (i, name))
        names = Fcons (build_string (name), names);
     }
+
   return names;
+#else
+  return Qnil;
+#endif
 }
 
 #ifdef subprocesses