Annotation of 43BSD/usr.bin/uucp/vms/uucp.h, revision 1.1

1.1     ! root        1: /*     $Header: uucp.h,v 1.14 84/10/12 20:42:00 rick Exp $ */
        !             2: /*     from: uucp.h    5.2     83/07/19        */
        !             3: 
        !             4: #include "stdio.h"
        !             5: 
        !             6: /*
        !             7:  * Determine local uucp name of this machine.
        !             8:  * Define one of the following:
        !             9:  *
        !            10:  * For UCB 4.1A and later systems, you will have the gethostname(2) call.
        !            11:  * If this call exists, define GETHOSTNAME.
        !            12:  *
        !            13:  * For USG 3.0 and later systems, you will have the uname(2) call.
        !            14:  * If this call exists, define UNAME.
        !            15:  *
        !            16:  * Some systems have a line of the form '#define sysname "myuucpname",'
        !            17:  * in the file /usr/include/whoami.h, to identify their machine.
        !            18:  * If your site does that, define WHOAMI.
        !            19:  *
        !            20:  * If your site has <whoami.h>, but you do not want to read
        !            21:  * that file every time uucp runs, you can compile sysname into uucp.
        !            22:  * This is faster and more reliable, but binaries do not port.
        !            23:  * If you want to do that, define CCWHOAMI.
        !            24:  *
        !            25:  * Some systems put the local uucp name in a single-line file
        !            26:  * named /etc/uucpname or /local/uucpname.
        !            27:  * If your site does that, define UUNAME.
        !            28:  *
        !            29:  * Systems running 3Com's UNET will have the getmyhname() call.
        !            30:  * If you want to, define GETMYHNAME.
        !            31:  *
        !            32:  * You should also define MYNANE to be your uucp name.
        !            33:  *
        !            34:  * For each of the above that are defined, uucp checks them in order.
        !            35:  * It stops on the first method that returns a non null name.
        !            36:  * If everything fails, it uses "unknown" for the system name.
        !            37:  */
        !            38: #define        GETHOSTNAME
        !            39: /*#define CCWHOAMI     */
        !            40: /* If the above fails ... */
        !            41: #define        MYNAME  "erewhon"
        !            42: 
        !            43: /*
        !            44:  * If you have it, include <sysexits.h> to use exit
        !            45:  * codes that will be understood by sendmail.
        !            46:  * Otherwise, define EX_NOHOST, EX_CANTCREAT, and EX_NOINPUT.
        !            47:  */
        !            48: #include <sysexits.h>
        !            49: /*#define EX_NOHOST    101*/
        !            50: /*#define EX_CANTCREAT 1*/
        !            51: /*#define EX_NOINPUT   2*/
        !            52: 
        !            53: /*
        !            54:  * Define the various kinds of connections to include.
        !            55:  * The complete list is in the condevs array in condevs.c
        !            56:  */
        !            57: /*#define DN11         /* standard dialer */
        !            58: /*#define DATAKIT      /* ATT's datakit */
        !            59: /*#define PNET         /* Purdue network */
        !            60: /*#define DF02         /* Dec's DF02/DF03 */
        !            61: /*#define HAYES                /* Hayes' Smartmodem */
        !            62: /*#define VENTEL       /* ventel dialer */
        !            63: /*#define VADIC                /* Racal-Vadic 3450 */
        !            64: /*#define RVMACS       /* Racal-Vadic MACS 831 */
        !            65: /*#define RVADIC       /* Racal-Vadic 831 */
        !            66: /*#define UNETTCP      /* 3Com's UNET */
        !            67: #define BSDTCP         /* 4.2bsd TCP/IP */
        !            68: /*#define PAD          /* X.25 PAD */
        !            69: /*#define MICOM                /* micom mux port */
        !            70: /*#define NOVATION     /* Novation modem */
        !            71: 
        !            72: #if defined(UNETTCP) || defined(BSDTCP)
        !            73: #define TCPIP
        !            74: #endif
        !            75: 
        !            76: #ifdef VENTEL
        !            77: /*
        !            78:  * We need a timer to write slowly to ventels.
        !            79:  * define INTERVALTIMER to use 4.2 bsd interval timer.
        !            80:  * define FASTTIMER if you have the nap() system call.
        !            81:  * define FTIME if you have the ftime() system call.
        !            82:  * define BUSYLOOP if you must do a busy loop.
        !            83:  * Look at uucpdelay() in condevs.c for details.
        !            84:  */
        !            85: #define        FTIME
        !            86: #endif
        !            87: 
        !            88: /*
        !            89:  * If your site is using "ndir.h" to retrofit the Berkeley
        !            90:  * directory reading routines, define NDIR.
        !            91:  * You will probably also have to set LIBNDIR in Makefile.
        !            92:  * Otherwise, <dir.h> is assumed to have the Berkeley directory definitions.
        !            93:  */
        !            94: #define        NDIR
        !            95: 
        !            96: /*
        !            97:  * If yours is a BTL system III, IV, or so-on site, define SYSIII.
        !            98:  */
        !            99: /*#define      SYSIII  */
        !           100: 
        !           101: /*
        !           102:  * If you are running 4.2bsd, define BSD4_2
        !           103:  */
        !           104: /*#define BSD4_2 */
        !           105: 
        !           106: /* for a EUNICE system, define VMS */
        !           107: #define        VMS
        !           108: 
        !           109: /*
        !           110:  * If you are using /etc/inetd with 4.2bsd, define BSDINETD
        !           111:  */
        !           112: /*#define BSDINETD*/
        !           113: 
        !           114: #define VMSDTR /* Turn on modem control on vms(works DTR) for
        !           115:                           develcon and gandalf ports to gain access */
        !           116: 
        !           117: /* define the last characters for ACU */
        !           118: #define ACULAST "-<"
        !           119: 
        !           120: /* define the value of WFMASK - for umask call - used for all uucp work files */
        !           121: #define WFMASK 0111
        !           122: 
        !           123: /* define UUSTAT if you need "uustat" command */
        !           124: /* #define UUSTAT      */
        !           125: 
        !           126: /*     define UUSUB if you need "uusub" command */
        !           127: /* #define UUSUB */
        !           128: 
        !           129: /* define the value of LOGMASK - for LOGFILE, SYSLOG, ERRLOG */
        !           130: #define        LOGMASK 0111
        !           131: 
        !           132: /* All files are given at least the following at the final destination */
        !           133: /* It is also the default mode, so '666' is recommended */
        !           134: /* and 444 is minimal (minimally useful, maximally annoying) */
        !           135: #define        BASEMODE        0666
        !           136: 
        !           137: /*
        !           138:  * Define NOSTRANGERS if you don't want to accept transactions from
        !           139:  * sites that are not in your L.sys file (see cico.c)
        !           140:  */
        !           141: /* #define NOSTRANGERS */
        !           142: 
        !           143: #define XQTDIR         "/usr/spool/uucp/XTMP"
        !           144: #define SQFILE         "/usr/lib/uucp/SQFILE"
        !           145: #define SQTMP          "/usr/lib/uucp/SQTMP"
        !           146: #define SLCKTIME       5400    /* system/device timeout (LCK.. files) */
        !           147: #define SEQFILE                "/usr/lib/uucp/SEQF"
        !           148: #define SYSFILE                "/usr/lib/uucp/L.sys"
        !           149: #define DEVFILE                "/usr/lib/uucp/L-devices"
        !           150: #define DIALFILE       "/usr/lib/uucp/L-dialcodes"
        !           151: #define USERFILE       "/usr/lib/uucp/USERFILE"
        !           152: #define        CMDFILE         "/usr/lib/uucp/L.cmds"
        !           153: 
        !           154: #define SPOOL          "/usr/spool/uucp"
        !           155: #define SQLOCK         "/usr/spool/uucp/LCK.SQ"
        !           156: #define SYSLOG         "/usr/spool/uucp/SYSLOG"
        !           157: #define PUBDIR         "/usr/spool/uucppublic"
        !           158: #define        CMDSDIR         "/usr/spool/uucp/C."
        !           159: #define        DATADIR         "/usr/spool/uucp/D."
        !           160: #define        XEQTDIR         "/usr/spool/uucp/X."
        !           161: 
        !           162: #define SEQLOCK                "LCK.SEQL"
        !           163: #define CMDPRE         'C'
        !           164: #define DATAPRE                'D'
        !           165: #define XQTPRE         'X'
        !           166: 
        !           167: #define LOGFILE        "/usr/spool/uucp/LOGFILE"
        !           168: #define ERRLOG "/usr/spool/uucp/ERRLOG"
        !           169: 
        !           170: #define RMTDEBUG       "AUDIT"
        !           171: #define CORRUPT                "CORRUPT"
        !           172: #define SQTIME         60
        !           173: #define TRYCALLS       2       /* number of tries to dial call */
        !           174: 
        !           175: #define LLEN   50
        !           176: #define MAXRQST        250
        !           177: 
        !           178: #define DEBUG(l, f, s) if (Debug >= l) fprintf(stderr, f, s); else
        !           179: 
        !           180: #define ASSERT(e, s1, s2, i1) if (!(e)) {assert(s1, s2, i1);cleanup(FAIL);}else
        !           181: 
        !           182: #define SAME 0
        !           183: #define ANYREAD 0444
        !           184: #define ANYWRITE 02
        !           185: #define FAIL -1
        !           186: #define SUCCESS 0
        !           187: #define CNULL (char *) 0
        !           188: #define STBNULL (struct sgttyb *) 0
        !           189: #define MASTER 1
        !           190: #define SLAVE 0
        !           191: #define MAXFULLNAME 256
        !           192: #define MAXMSGTIME 45
        !           193: #define NAMESIZE 256
        !           194: #define EOTMSG "\04\n\04\n"
        !           195: #define CALLBACK 1
        !           196: 
        !           197:        /*  commands  */
        !           198: #define SHELL          "/bin/sh"
        !           199: #define MAIL           "mail"
        !           200: #define UUCICO         "/usr/lib/uucp/uucico"
        !           201: #define UUXQT          "/usr/lib/uucp/uuxqt"
        !           202: #define UUCP           "uucp"
        !           203: #define        STARTUUCP       "/usr/lib/uucp/startuucp"
        !           204: 
        !           205:        /*  call connect fail stuff  */
        !           206: #define CF_SYSTEM      -1
        !           207: #define CF_TIME                -2
        !           208: #define CF_LOCK                -3
        !           209: #define        CF_NODEV        -4
        !           210: #define CF_DIAL                -5
        !           211: #define CF_LOGIN       -6
        !           212: 
        !           213: #define F_NAME 0
        !           214: #define F_TIME 1
        !           215: #define F_LINE 2
        !           216: #define F_CLASS 3      /* an optional prefix and the speed */
        !           217: #define F_PHONE 4
        !           218: #define F_LOGIN 5
        !           219: 
        !           220: #define MAXPH  60      /* maximum length of a phone number */
        !           221: 
        !           222:        /* This structure tells how to get to a device */
        !           223: struct condev {
        !           224:        char *CU_meth;          /* method, such as 'ACU' or 'DIR' */
        !           225:        char *CU_brand;         /* brand, such as 'Hayes' or 'Vadic' */
        !           226:        int (*CU_gen)();        /* what to call to search for brands */
        !           227:        int (*CU_open)();       /* what to call to open brand */
        !           228:        int (*CU_clos)();       /* what to call to close brand */
        !           229: };
        !           230: 
        !           231:        /* This structure tells about a device */
        !           232: struct Devices {
        !           233:        char D_type[20];
        !           234:        char D_line[20];
        !           235:        char D_calldev[20];
        !           236:        char D_class[20];
        !           237:        int D_speed;
        !           238:        char D_brand[20];       /* brand name, as 'Hayes' or 'Vadic' */
        !           239: };
        !           240: 
        !           241:        /*  system status stuff  */
        !           242: #define SS_OK          0
        !           243: #define SS_FAIL                4
        !           244: #define SS_NODEVICE    1
        !           245: #define SS_CALLBACK    2
        !           246: #define SS_INPROGRESS  3
        !           247: #define SS_BADSEQ      5
        !           248: 
        !           249:        /*  fail/retry parameters  */
        !           250: #define RETRYTIME 600
        !           251: #define MAXRECALLS 20
        !           252: 
        !           253:        /*  stuff for command execution  */
        !           254: #define X_RQDFILE      'F'
        !           255: #define X_STDIN                'I'
        !           256: #define X_STDOUT       'O'
        !           257: #define X_CMD          'C'
        !           258: #define X_USER         'U'
        !           259: #define X_SENDFILE     'S'
        !           260: #define        X_NONOTI        'N'
        !           261: #define X_RETURNTO     'R'
        !           262: #define        X_NONZERO       'Z'
        !           263: #define X_LOCK         "LCK.XQT"
        !           264: #define X_LOCKTIME     3600
        !           265: 
        !           266: #define WKDSIZE 100    /*  size of work dir name  */
        !           267: 
        !           268: extern int Ifn, Ofn;
        !           269: extern char Rmtname[];
        !           270: extern char User[];
        !           271: extern char Loginuser[];
        !           272: extern char *Spool;
        !           273: extern char Myname[];
        !           274: extern char Myfullname[];
        !           275: extern int Debug;
        !           276: extern int Bspeed;
        !           277: extern char Wrkdir[];
        !           278: extern long Retrytime;
        !           279: extern short Usrf;
        !           280: extern int IsTcpIp;
        !           281: extern char Progname[];
        !           282: extern int (*CU_end)();
        !           283: extern struct condev condevs[];
        !           284: 
        !           285: extern char DLocal[], DLocalX[], *subfile(), *subdir();
        !           286: 
        !           287: /* Commonly called routines which return non-int value */
        !           288: extern char *ttyname(), *strcpy(), *strcat(), *index(), *rindex(),
        !           289:                *fgets(), *calloc(), *malloc(),
        !           290:                *cfgets();
        !           291: extern long lseek();
        !           292: extern FILE *rpopen();

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.