home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / N / TCPIP / NETKIT-B.05 / NETKIT-B / NetKit-B-0.05 / lpr / common_source / lp.h,v < prev    next >
Encoding:
Text File  |  1994-05-23  |  5.0 KB  |  148 lines

  1. head    1.1;
  2. access;
  3. symbols;
  4. locks
  5.     rzsfl:1.1; strict;
  6. comment    @ * @;
  7.  
  8.  
  9. 1.1
  10. date    94.05.23.09.04.57;    author rzsfl;    state Exp;
  11. branches;
  12. next    ;
  13.  
  14.  
  15. desc
  16. @Original
  17. @
  18.  
  19.  
  20. 1.1
  21. log
  22. @Initial revision
  23. @
  24. text
  25. @/*
  26.  * Copyright (c) 1983 Regents of the University of California.
  27.  * All rights reserved.
  28.  *
  29.  * Redistribution and use in source and binary forms, with or without
  30.  * modification, are permitted provided that the following conditions
  31.  * are met:
  32.  * 1. Redistributions of source code must retain the above copyright
  33.  *    notice, this list of conditions and the following disclaimer.
  34.  * 2. Redistributions in binary form must reproduce the above copyright
  35.  *    notice, this list of conditions and the following disclaimer in the
  36.  *    documentation and/or other materials provided with the distribution.
  37.  * 3. All advertising materials mentioning features or use of this software
  38.  *    must display the following acknowledgement:
  39.  *    This product includes software developed by the University of
  40.  *    California, Berkeley and its contributors.
  41.  * 4. Neither the name of the University nor the names of its contributors
  42.  *    may be used to endorse or promote products derived from this software
  43.  *    without specific prior written permission.
  44.  *
  45.  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  46.  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  47.  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  48.  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  49.  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  50.  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  51.  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  52.  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  53.  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  54.  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  55.  * SUCH DAMAGE.
  56.  *
  57.  *    from: @@(#)lp.h    5.5 (Berkeley) 6/1/90
  58.  *    $Id: lp.h,v 1.3 1993/12/08 00:47:03 jtc Exp $
  59.  */
  60.  
  61. /*
  62.  * Global definitions for the line printer system.
  63.  */
  64.  
  65. #include <stdio.h>
  66. #include <sys/param.h>
  67. #include <sys/file.h>
  68. #include <dirent.h>
  69. #include <sys/stat.h>
  70. #include <sys/socket.h>
  71. #include <sys/un.h>
  72. #include <netinet/in.h>
  73. #include <netdb.h>
  74. #include <pwd.h>
  75. #include <syslog.h>
  76. #include <signal.h>
  77. #include <sys/wait.h>
  78. #include <sgtty.h>
  79. #include <ctype.h>
  80. #include <errno.h>
  81. #include "lp.local.h"
  82.  
  83. extern int    DU;        /* daeomon user-id */
  84. extern int    MX;        /* maximum number of blocks to copy */
  85. extern int    MC;        /* maximum number of copies allowed */
  86. extern char    *LP;        /* line printer device name */
  87. extern char    *RM;        /* remote machine name */
  88. extern char    *RG;        /* restricted group */
  89. extern char    *RP;        /* remote printer name */
  90. extern char    *LO;        /* lock file name */
  91. extern char    *ST;        /* status file name */
  92. extern char    *SD;        /* spool directory */
  93. extern char    *AF;        /* accounting file */
  94. extern char    *LF;        /* log file for error messages */
  95. extern char    *OF;        /* name of output filter (created once) */
  96. extern char    *IF;        /* name of input filter (created per job) */
  97. extern char    *RF;        /* name of fortran text filter (per job) */
  98. extern char    *TF;        /* name of troff(1) filter (per job) */
  99. extern char    *NF;        /* name of ditroff(1) filter (per job) */
  100. extern char    *DF;        /* name of tex filter (per job) */
  101. extern char    *GF;        /* name of graph(1G) filter (per job) */
  102. extern char    *VF;        /* name of raster filter (per job) */
  103. extern char    *CF;        /* name of cifplot filter (per job) */
  104. extern char    *FF;        /* form feed string */
  105. extern char    *TR;        /* trailer string to be output when Q empties */
  106. extern short    SC;        /* suppress multiple copies */
  107. extern short    SF;        /* suppress FF on each print job */
  108. extern short    SH;        /* suppress header page */
  109. extern short    SB;        /* short banner instead of normal header */
  110. extern short    HL;        /* print header last */
  111. extern short    RW;        /* open LP for reading and writing */
  112. extern short    PW;        /* page width */
  113. extern short    PX;        /* page width in pixels */
  114. extern short    PY;        /* page length in pixels */
  115. extern short    PL;        /* page length */
  116. extern short    BR;        /* baud rate if lp is a tty */
  117. extern int    FC;        /* flags to clear if lp is a tty */
  118. extern int    FS;        /* flags to set if lp is a tty */
  119. extern int    XC;        /* flags to clear for local mode */
  120. extern int    XS;        /* flags to set for local mode */
  121. extern short    RS;        /* restricted to those with local accounts */
  122.  
  123. extern char    line[BUFSIZ];
  124. extern char    pbuf[];        /* buffer for printcap entry */
  125. extern char    *bp;        /* pointer into ebuf for pgetent() */
  126. extern char    *name;        /* program name */
  127. extern char    *printer;    /* printer name */
  128. extern char    host[32];    /* host machine name */
  129. extern char    *from;        /* client's machine name */
  130. extern int    sendtorem;    /* are we sending to a remote? */
  131. extern int    errno;
  132.  
  133. /*
  134.  * Structure used for building a sorted list of control files.
  135.  */
  136. struct queue {
  137.     time_t    q_time;            /* modification time */
  138.     char    q_name[MAXNAMLEN+1];    /* control file name */
  139. };
  140.  
  141. char    *pgetstr();
  142. char    *malloc();
  143. char    *getenv();
  144. char    *index();
  145. char    *rindex();
  146. char    *checkremote();
  147. @
  148.