source: trunk/athena/bin/lpr/lp.h @ 12350

Revision 12350, 4.3 KB checked in by ghudson, 26 years ago (diff)
Some RCS ID cleanup: delete $Log$ and replace other RCS keywords with $Id$.
Line 
1/*
2 *      $Id: lp.h,v 1.17 1999-01-22 23:10:37 ghudson Exp $
3 */
4
5/*
6 * Copyright (c) 1983 Regents of the University of California.
7 * All rights reserved.  The Berkeley software License Agreement
8 * specifies the terms and conditions for redistribution.
9 *
10 *      @(#)lp.h        5.1 (Berkeley) 6/6/85
11 */
12
13/*
14 * Global definitions for the line printer system.
15 */
16
17#ifdef POSIX
18#include <unistd.h>
19#endif
20#include <stdio.h>
21#include <sys/param.h>
22#include <sys/types.h>
23#include <sys/file.h>
24#include <fcntl.h>
25#ifdef POSIX
26#include <dirent.h>
27#else
28#include <sys/dir.h>
29#endif
30#include <sys/stat.h>
31#include <sys/socket.h>
32#include <sys/un.h>
33#include <netinet/in.h>
34#include <netdb.h>
35#include <pwd.h>
36#include <syslog.h>
37#include <signal.h>
38#ifdef _AIX
39#undef _BSD
40#endif
41#include <sys/wait.h>
42#ifdef _AIX
43#define _BSD 44
44#include <sys/ioctl.h>
45#endif
46#ifdef POSIX
47#include <termios.h>
48#else
49#include <sgtty.h>
50#endif
51#include <ctype.h>
52#include <errno.h>
53#include <string.h>
54#include "lp.local.h"
55
56
57
58#ifdef KERBEROS
59#include <krb.h>
60#define KLPR_SERVICE "rcmd"
61#endif /* KERBEROS */
62
63extern int      DU;             /* daeomon user-id */
64extern int      MX;             /* maximum number of blocks to copy */
65extern int      MC;             /* maximum number of copies allowed */
66extern char     *LP;            /* line printer device name */
67extern char     *RM;            /* remote machine name */
68extern char     *RG;            /* restricted group */
69extern char     *RP;            /* remote printer name */
70extern char     *LO;            /* lock file name */
71extern char     *ST;            /* status file name */
72extern char     *SD;            /* spool directory */
73extern char     *AF;            /* accounting file */
74extern char     *LF;            /* log file for error messages */
75extern char     *OF;            /* name of output filter (created once) */
76extern char     *IF;            /* name of input filter (created per job) */
77extern char     *RF;            /* name of fortran text filter (per job) */
78extern char     *TF;            /* name of troff(1) filter (per job) */
79extern char     *NF;            /* name of ditroff(1) filter (per job) */
80extern char     *DF;            /* name of tex filter (per job) */
81extern char     *GF;            /* name of graph(1G) filter (per job) */
82extern char     *VF;            /* name of raster filter (per job) */
83extern char     *CF;            /* name of cifplot filter (per job) */
84extern char     *FF;            /* form feed string */
85extern char     *TR;            /* trailer string to be output when Q empties */
86extern char     *MS;            /* list of tty modes to set or clear */
87extern short    SC;             /* suppress multiple copies */
88extern short    SF;             /* suppress FF on each print job */
89extern short    SH;             /* suppress header page */
90extern short    SB;             /* short banner instead of normal header */
91extern short    HL;             /* print header last */
92extern short    RW;             /* open LP for reading and writing */
93extern short    PW;             /* page width */
94extern short    PX;             /* page width in pixels */
95extern short    PY;             /* page length in pixels */
96extern short    PL;             /* page length */
97extern short    BR;             /* baud rate if lp is a tty */
98extern int      FC;             /* flags to clear if lp is a tty */
99extern int      FS;             /* flags to set if lp is a tty */
100extern int      XC;             /* flags to clear for local mode */
101extern int      XS;             /* flags to set for local mode */
102extern short    RS;             /* restricted to those with local accounts */
103#ifdef PQUOTA
104extern char     *RQ;            /* Name of remote quota server */
105extern int      CP;             /* Cost per page */
106extern char     *QS;            /* Quota service for printer */
107#endif /* PQUOTA */
108#ifdef LACL
109extern char     *AC;            /* Local ACL file to use */
110extern short    PA;             /* ACL file used as positive ACL */
111extern short    RA;             /* Restricted host access */
112#endif /* LACL */
113
114extern char     line[BUFSIZ];
115extern char     pbuf[];         /* buffer for printcap entry */
116extern char     *bp;            /* pointer into ebuf for pgetent() */
117extern char     *name;          /* program name */
118extern char     *printer;       /* printer name */
119extern char     host[MAXHOSTNAMELEN + 1];       /* host machine name */
120extern char     *from;          /* client's machine name */
121extern int      errno;
122#ifdef HESIOD
123extern char     alibuf[BUFSIZ/2]; /* buffer for printer alias */
124#endif
125
126#ifdef KERBEROS
127extern int      use_kerberos;
128extern int      kerberos_cf;
129extern char     kprincipal[];
130extern char     kinstance[];
131extern char     krealm[];
132#endif /* KERBEROS */
133
134/*
135 * Structure used for building a sorted list of control files.
136 */
137struct queue_ {
138        time_t  q_time;                 /* modification time */
139        char    q_name[MAXNAMLEN+1];    /* control file name */
140};
141
142char    *pgetstr();
143#ifdef vax
144char    *malloc();
145#endif
146char    *getenv();
147
148
149#define UNLINK unlink
150#ifdef PQUOTA
151#define QUOTA_QUERY_VERSION '1'
152#endif
Note: See TracBrowser for help on using the repository browser.