pkgsrc/x11/xview-lib/patches/patch-de
kristerw 0063ba76e8 Make this compile on NetBSD 2.0 too.
Thanks to Douglas Wade Needham for providing patches (on pkgsrc-bulk@).
2004-09-30 20:38:28 +00:00

32 lines
861 B
Text

$NetBSD: patch-de,v 1.2 2004/09/30 20:38:28 kristerw Exp $
--- lib/libxview/textsw/es_file.c.orig 1993-06-29 07:17:34.000000000 +0200
+++ lib/libxview/textsw/es_file.c 2004-09-30 22:12:38.000000000 +0200
@@ -88,10 +88,11 @@
#ifdef SVR4
#include <stdlib.h>
#include <dirent.h>
+#include <sys/errno.h>
#else
#include <sys/dir.h>
+#include <errno.h>
#endif /* SVR4 */
-#include <sys/errno.h>
#include <sys/param.h>
#include <sys/types.h>
#include <sys/stat.h>
@@ -109,9 +110,14 @@
#include <xview_private/txt_18impl.h>
+#if (defined(BSD) && (BSD >= 199306))
+extern const char *const sys_err_list[];
+extern off_t lseek();
+#else
extern int errno, sys_nerr;
extern char *sys_errlist[];
extern long lseek();
+#endif
static void update_read_buf(); /* update the read buf if overlaps write buf */
static Es_status es_file_commit();