1*57117Smuller /*- 2*57117Smuller * Copyright (c) 1992 Keith Muller. 3*57117Smuller * Copyright (c) 1992 The Regents of the University of California. 4*57117Smuller * All rights reserved. 5*57117Smuller * 6*57117Smuller * This code is derived from software contributed to Berkeley by 7*57117Smuller * Keith Muller of the University of California, San Diego. 8*57117Smuller * 9*57117Smuller * %sccs.include.redist.c% 10*57117Smuller * 11*57117Smuller * @(#)options.h 1.1 (Berkeley) 12/13/92 12*57117Smuller */ 13*57117Smuller 14*57117Smuller /* 15*57117Smuller * Constants used to specify the legal sets of flags in pax. For each major 16*57117Smuller * operation mode of pax, a set of illegal flags is defined. If any one of 17*57117Smuller * those illegal flags are found set, we scream and exit 18*57117Smuller */ 19*57117Smuller #define NONE "none" 20*57117Smuller 21*57117Smuller /* 22*57117Smuller * flags (one for each option). 23*57117Smuller */ 24*57117Smuller #define AF 0x00000001 25*57117Smuller #define BF 0x00000002 26*57117Smuller #define CF 0x00000004 27*57117Smuller #define DF 0x00000008 28*57117Smuller #define FF 0x00000010 29*57117Smuller #define IF 0x00000020 30*57117Smuller #define KF 0x00000040 31*57117Smuller #define LF 0x00000080 32*57117Smuller #define NF 0x00000100 33*57117Smuller #define OF 0x00000200 34*57117Smuller #define PF 0x00000400 35*57117Smuller #define RF 0x00000800 36*57117Smuller #define SF 0x00001000 37*57117Smuller #define TF 0x00002000 38*57117Smuller #define UF 0x00004000 39*57117Smuller #define VF 0x00008000 40*57117Smuller #define WF 0x00010000 41*57117Smuller #define XF 0x00020000 42*57117Smuller #define CBF 0x00040000 /* nonstandard extension */ 43*57117Smuller #define CEF 0x00080000 /* nonstandard extension */ 44*57117Smuller #define CGF 0x00100000 /* nonstandard extension */ 45*57117Smuller #define CHF 0x00200000 /* nonstandard extension */ 46*57117Smuller #define CLF 0x00400000 47*57117Smuller #define CTF 0x00800000 /* nonstandard extension */ 48*57117Smuller #define CUF 0x01000000 /* nonstandard extension */ 49*57117Smuller #define CXF 0x02000000 50*57117Smuller #define CZF 0x04000000 /* nonstandard extension */ 51*57117Smuller 52*57117Smuller /* 53*57117Smuller * ascii string indexed by bit position above (alter the above and you must 54*57117Smuller * alter this string) used to tell the user what flags caused us to complain 55*57117Smuller */ 56*57117Smuller #define FLGCH "abcdfiklnoprstuvwxBEGHLTUXZ" 57*57117Smuller 58*57117Smuller /* 59*57117Smuller * legal pax operation bit patterns 60*57117Smuller */ 61*57117Smuller 62*57117Smuller #define ISLIST(x) (((x) & (RF|WF)) == 0) 63*57117Smuller #define ISEXTRACT(x) (((x) & (RF|WF)) == RF) 64*57117Smuller #define ISARCHIVE(x) (((x) & (AF|RF|WF)) == WF) 65*57117Smuller #define ISAPPND(x) (((x) & (AF|RF|WF)) == (AF|WF)) 66*57117Smuller #define ISCOPY(x) (((x) & (RF|WF)) == (RF|WF)) 67*57117Smuller #define ISWRITE(x) (((x) & (RF|WF)) == WF) 68*57117Smuller 69*57117Smuller /* 70*57117Smuller * Illegal option flag subsets based on pax operation 71*57117Smuller */ 72*57117Smuller 73*57117Smuller #define BDLIST (AF|BF|IF|KF|LF|OF|PF|RF|TF|UF|WF|XF|CBF|CHF|CLF|CXF|CZF) 74*57117Smuller #define BDEXTR (AF|BF|LF|TF|WF|XF|CBF|CHF|CLF|CXF) 75*57117Smuller #define BDARCH (CF|KF|LF|NF|PF|RF|CEF|CZF) 76*57117Smuller #define BDCOPY (AF|BF|FF|OF|XF|CBF|CEF) 77