summaryrefslogtreecommitdiff
path: root/src/h-system.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/h-system.h')
-rw-r--r--src/h-system.h141
1 files changed, 141 insertions, 0 deletions
diff --git a/src/h-system.h b/src/h-system.h
new file mode 100644
index 00000000..2d28e45d
--- /dev/null
+++ b/src/h-system.h
@@ -0,0 +1,141 @@
+/* File: h-system.h */
+
+#ifndef INCLUDED_H_SYSTEM_H
+#define INCLUDED_H_SYSTEM_H
+
+/*
+ * Include the basic "system" files.
+ *
+ * Make sure all "system" constants/macros are defined.
+ * Make sure all "system" functions have "extern" declarations.
+ *
+ * This file is a big hack to make other files less of a hack.
+ * This file has been rebuilt -- it may need a little more work.
+ *
+ * It is (very) unlikely that VMS will work without help, primarily
+ * because VMS does not use the "ASCII" character set.
+ */
+
+
+#include <stdio.h>
+#include <ctype.h>
+#include <errno.h>
+
+#if defined(NeXT)
+# include <libc.h>
+#else
+# include <stdlib.h>
+#endif
+
+
+#ifdef SET_UID
+
+# include <sys/types.h>
+
+# if defined(Pyramid) || defined(NeXT) || defined(SUNOS) || \
+ defined(NCR3K) || defined(SUNOS) || defined(ibm032) || \
+ defined(__osf__) || defined(ISC) || defined(SGI) || \
+ defined(linux)
+# include <sys/time.h>
+# endif
+
+# if !defined(SGI) && !defined(ULTRIX)
+# include <sys/timeb.h>
+# endif
+
+#endif
+
+
+#include <time.h>
+
+
+
+#ifdef MACINTOSH
+# include <unix.h>
+#endif
+
+#if defined(WINDOWS) || defined(MSDOS) || defined(USE_EMX)
+# include <io.h>
+#endif
+
+#if !defined(MACINTOSH) && !defined(AMIGA) && \
+ !defined(ACORN) && !defined(VM) && !defined(__MWERKS__)
+# if defined(__TURBOC__) || defined(__WATCOMC__)
+# include <mem.h>
+# else
+# include <memory.h>
+# endif
+#endif
+
+
+#if !defined(NeXT) && !defined(__MWERKS__) && !defined(ACORN)
+# include <fcntl.h>
+#endif
+
+
+#ifdef SET_UID
+
+# ifndef USG
+# include <sys/param.h>
+# include <sys/file.h>
+# endif
+
+# ifdef linux
+# include <sys/file.h>
+# endif
+
+# include <pwd.h>
+
+# include <unistd.h>
+
+# include <sys/stat.h>
+
+# if defined(SOLARIS)
+# include <netdb.h>
+# endif
+
+#endif
+
+#ifdef __DJGPP__
+#include <unistd.h>
+#endif /* __DJGPP__ */
+
+#ifdef SET_UID
+
+#ifdef USG
+# include <string.h>
+#else
+# include <strings.h>
+# ifndef strstr
+extern char *strstr();
+# endif
+# ifndef strchr
+extern char *strchr();
+# endif
+# ifndef strrchr
+extern char *strrchr();
+# endif
+#endif
+
+#else
+
+# include <string.h>
+
+#endif
+
+
+
+#if !defined(linux) && !defined(__MWERKS__) && !defined(ACORN)
+extern long atol();
+#endif
+
+
+#include <stdarg.h>
+
+
+#endif
+
+/* There was a bug introduced in 10.4.11; working around it */
+#ifdef __APPLE__
+#define GETLOGIN_BROKEN
+#endif