1/* 2 * This program is free software; you can redistribute it and/or 3 * modify it under the terms of the GNU General Public License as 4 * published by the Free Software Foundation; either version 2 of 5 * the License, or (at your option) any later version. 6 * 7 * This program is distributed in the hope that it will be useful, 8 * but WITHOUT ANY WARRANTY; without even the implied warranty of 9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10 * GNU General Public License for more details. 11 * 12 * You should have received a copy of the GNU General Public License 13 * along with this program; if not, write to the Free Software 14 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, 15 * MA 02111-1307 USA 16 */ 17/*************************************************************************** 18 * LPRng - An Extended Print Spooler System 19 * 20 * Copyright 1988-2003, Patrick Powell, San Diego, CA 21 * papowell@lprng.com 22 * See LICENSE for conditions of use. 23 * $Id: lpr.h,v 1.1.1.1 2008/10/15 03:28:27 james26_jang Exp $ 24 ***************************************************************************/ 25 26 27 28#ifndef _LPR_1_ 29#define _LPR_1_ 30 31EXTERN char *Accntname_JOB; /* Accounting name: PLP 'R' control file option */ 32EXTERN int Auth_JOB; /* Use authentication */ 33EXTERN int Binary_JOB; /* Binary format: 'l' Format */ 34EXTERN char *Bnrname_JOB; /* Banner name: RFC 'L' option */ 35EXTERN char *Classname_JOB; /* Class name: RFC 'C' option */ 36EXTERN int Copies_JOB; /* Copies */ 37EXTERN int Direct_JOB; /* Connect and send to TCP/IP port */ 38EXTERN int Format_JOB; /* format for printing: lower case letter */ 39EXTERN char *Font1_JOB; /* Font information 1 */ 40EXTERN char *Font2_JOB; /* Font information 2 */ 41EXTERN char *Font3_JOB; /* Font information 3 */ 42EXTERN char *Font4_JOB; /* Font information 4 */ 43EXTERN int Indent_JOB; /* indent: RFC 'I' option */ 44EXTERN char *Jobname_JOB; /* Job name: RFC 'J' option */ 45EXTERN int Lpr_zero_file_JOB; /* LPR does file filtering and job flattening */ 46EXTERN int Lpr_bounce_JOB; /* LPR does file filtering and job flattening */ 47EXTERN char *Mailname_JOB; /* Mail name: RFC 'M' option */ 48EXTERN int No_header_JOB; /* No header flag: no L option in control file */ 49EXTERN int Priority_JOB; /* Priority */ 50EXTERN char *Printer_JOB; /* Printer passed as option */ 51EXTERN char *Prtitle_JOB; /* Pr title: RFC 'T' option */ 52EXTERN int Pwidth_JOB; /* Width paper: RFC 'W' option */ 53EXTERN int Removefiles_JOB; /* Remove files */ 54EXTERN char *Username_JOB; /* Specified with the -U option */ 55EXTERN char *Zopts_JOB; /* Z options */ 56EXTERN char * User_filter_JOB; /* User specified filter for job files */ 57 58extern struct jobwords Lpr_parms[]; /* parameters for LPR */ 59EXTERN int LP_mode_JOB; /* look like LP */ 60EXTERN int Silent_JOB; /* lp -s option */ 61EXTERN int Job_number; 62 63/* PROTOTYPES */ 64int main(int argc, char *argv[], char *envp[]); 65void Get_parms(int argc, char *argv[] ); 66void prmsg( char **msg ); 67void usage(void); 68int Make_job( struct job *job ); 69void get_job_number( struct job *job ); 70double Copy_STDIN( struct job *job ); 71double Check_files( struct job *job ); 72int Check_lpr_printable(char *file, int fd, struct stat *statb, int format ); 73int is_exec( char *buf, int n); 74int is_arch(char *buf, int n); 75void Dienoarg(int option); 76void Check_int_dup (int option, int *value, char *arg, int maxvalue); 77void Check_str_dup(int option, char **value, char *arg, int maxlen ); 78void Check_dup(int option, int *value); 79 80#endif 81