bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[21.1] Patch for mips-sony-bsd (Sony NEWS-OS 4.2R)


From: NAKAJI Hiroyuki
Subject: [21.1] Patch for mips-sony-bsd (Sony NEWS-OS 4.2R)
Date: 02 Nov 2001 13:01:55 +0900
User-agent: T-gnus/6.15.3 (based on Oort Gnus v0.03) (revision 05) SEMI/1.14.3 (Ushinoya) FLIM/1.14.3 (Unebigoryƍmae) APEL/10.3 Emacs/20.7 (i386--freebsd) MULE/4.0 (HANANOEN)

Hi,

I need attached change to build emacs-21.1 on my Sony NEWS-OS 4.2R
configured as mips-sony-bsd. It should be applied in emacs-21.1/src
directory.

The change for gmalloc.c is tricky. Because NEWS-OS 4.x is not fully
POSIX, malloc() functions are declared as 'char *malloc()' and so on.

According to malloc(3), these function's declareration is:

     char *malloc(size)
     unsigned size;

     free(ptr)
     char *ptr;

     char *realloc(ptr, size)
     char *ptr;
     unsigned size;

     char *calloc(nelem, elsize)
     unsigned nelem, elsize;

     char *alloca(size)
     int size;

This is not POSIX compatible, but gcc assumes the system should be POSIX
and there are conflicts against these functions.
-- 
NAKAJI Hiroyuki

--- editfns.c.orig      Fri Nov  2 12:34:41 2001
+++ editfns.c   Fri Nov  2 12:35:26 2001
@@ -33,6 +33,8 @@
 #include <unistd.h>
 #endif
 
+#include <ctype.h>
+
 #include "lisp.h"
 #include "intervals.h"
 #include "buffer.h"
--- gmalloc.c.orig      Wed Apr 18 19:25:48 2001
+++ gmalloc.c   Fri Nov  2 11:52:04 2001
@@ -36,8 +36,9 @@
 #include <config.h>
 #endif
 
-#if defined __cplusplus || (defined (__STDC__) && __STDC__) || \
-  defined STDC_HEADERS || defined PROTOTYPES
+#if ( defined __cplusplus || (defined (__STDC__) && __STDC__) || \
+  defined STDC_HEADERS || defined PROTOTYPES ) && \
+  !(defined(__sony_news__) && defined(__SYSTYPE_BSD__))
 #undef PP
 #define        PP(args)        args
 #undef __ptr_t
--- xfns.c.orig Wed Sep 26 02:42:49 2001
+++ xfns.c      Fri Nov  2 11:52:07 2001
@@ -22,6 +22,7 @@
 #include <config.h>
 #include <signal.h>
 #include <stdio.h>
+#include <unistd.h>
 #include <math.h>
 
 /* This makes the fields of a Display accessible, in Xlib header files.  */



reply via email to

[Prev in Thread] Current Thread [Next in Thread]