summaryrefslogtreecommitdiff
path: root/sys/src/cmd/postscript/postio/ifdef.h
diff options
context:
space:
mode:
authorTaru Karttunen <taruti@taruti.net>2011-03-30 15:46:40 +0300
committerTaru Karttunen <taruti@taruti.net>2011-03-30 15:46:40 +0300
commite5888a1ffdae813d7575f5fb02275c6bb07e5199 (patch)
treed8d51eac403f07814b9e936eed0c9a79195e2450 /sys/src/cmd/postscript/postio/ifdef.h
Import sources from 2011-03-30 iso image
Diffstat (limited to 'sys/src/cmd/postscript/postio/ifdef.h')
-rwxr-xr-xsys/src/cmd/postscript/postio/ifdef.h66
1 files changed, 66 insertions, 0 deletions
diff --git a/sys/src/cmd/postscript/postio/ifdef.h b/sys/src/cmd/postscript/postio/ifdef.h
new file mode 100755
index 000000000..f158c46db
--- /dev/null
+++ b/sys/src/cmd/postscript/postio/ifdef.h
@@ -0,0 +1,66 @@
+/*
+ *
+ * Conditional compilation definitions needed in ifdef.c and postio.c.
+ *
+ */
+
+#ifdef SYSV
+#include <termio.h>
+
+#ifdef DKSTREAMS
+#include <sys/stream.h>
+#include <sys/stropts.h>
+#endif
+
+#endif
+
+#ifdef V9
+#include <sys/filio.h>
+#include <sys/ttyio.h>
+
+extern int tty_ld;
+#endif
+
+#ifdef BSD4_2
+#include <sgtty.h>
+#include <sys/time.h>
+#include <errno.h>
+
+#define FD_ZERO(s) (s) = 0
+#define FD_SET(n,s) (s) |= 1 << (n)
+
+extern int errno;
+#endif
+
+#ifdef DKHOST
+#include <dk.h>
+#include <sysexits.h>
+
+extern char *dtnamer();
+extern int dkminor();
+#endif
+
+/*
+ *
+ * External variable declarations - most (if not all) are defined in postio.c and
+ * needed by the routines in ifdef.c.
+ *
+ */
+
+extern char *line; /* printer is on this line */
+extern int ttyi; /* input */
+extern int ttyo; /* and output file descriptors */
+extern FILE *fp_log; /* just for DKHOST stuff */
+
+extern char mesg[]; /* exactly what came back on ttyi */
+extern char *endmesg; /* one in front of last free slot in mesg */
+extern int next; /* next character goes in mesg[next] */
+
+extern short baudrate; /* printer is running at this speed */
+extern int stopbits; /* and expects this many stop bits */
+extern int interactive; /* TRUE for interactive mode */
+
+extern int whatami; /* a READ or WRITE process - or both */
+extern int canread; /* allows reads */
+extern int canwrite; /* and writes if TRUE */
+