# 2.11BSD#431 - /usr/ingres/source/unix.h

##### Macros

    IALLOC            X
    IFBLK             X
    IFCHR             X
    IFDIR             X
    IFMT              X
    MAXFILES          X
    USERINGRES        X
    setexit           X
    xV7_UNIX          X

##### struct's

    sgttyb            X
    stat              X

       1: #
       2: /*
       3: **	COPYRIGHT
       4: **
       5: **	The Regents of the University of California
       6: **
       7: **	1977
       8: **
       9: **	This program material is the property of the
      10: **	Regents of the University of California and
      11: **	may not be reproduced or disclosed without
      12: **	the prior written permission of the owner.
      13: */
      14:
      15:
      16:
      17: /*
      18: **  This header file contains everything that we at Berkeley
      19: **	think might vary from system to system.  Before
      20: **	compiling INGRES you should eyeball this file to see
      21: **	if your system is consistant with us.
      22: **
      23: **	History:
      24: **		8/15/79 (eric) (6.2/7) -- added xV7_UNIX flag.
      25: **			Changed 'struct inode' to 'struct stat'
      26: **			for v7 compatibility, and changed the
      27: **			member names.
      28: */
      29:
      30:
      31:
      32:
      33: /*
      34: **  UNIX version flags.
      35: **	The following flags define what version of UNIX is being run.
      36: **	They should be set as follows:
      37: **
      38: **	Bell-style version six UNIX, with 8-bit user id's and 8-bit
      39: **	group id's, fetched with calls to getuid() and getgid()
      40: **	respectively, and stored in the passwd file as two separate
      41: **	eight-bit fields:
      42: **		Set the xV6_UNIX flag only.
      43: **
      44: **	Berkeley-style version 6/7x-05a UNIX, with a single 16-bit
      45: **	user id and no group id (and no getgid() or setgid() calls),
      46: **	and stored in the passwd file as two separate eight-bit fields,
      47: **	combined to make a single 16-bit field:
      48: **		Set the xB_UNIX flag only.
      49: **
      50: **	Bell-style version seven UNIX, with 16-bit user id's and
      51: **	16-bit group id's, fetched with calls to getuid() and
      52: **	getgid() respectively, and stored in the passwd file as
      53: **	two separate 16-bit fields:
      54: **		Set the xV7_UNIX flag only.
      55: */
      56:
      57: /* set for version seven */
      58: /* # define	xV6_UNIX	/* Bell v6 UNIX flag */
      59: # define    xV7_UNIX    /* Bell v7 UNIX flag */
      60: /* # define	xB_UNIX		/* Berkeley UNIX flag */
      61:
      62:
      63: /*
      64: **  Maximum number of open files per process.
      65: **  Must match 'NOFILE' entry in /usr/sys/param.h
      66: */
      67:
      68: # define    MAXFILES    30
      69:
      70:
      71: /*
      72: **	USERINGRES is the UNIX login name of the INGRES superuser,
      73: **		normally "ingres" of course.  The root of this persons
      74: **		subtree as listed in /etc/passwd becomes the root of
      75: **		the INGRES subtree.
      76: */
      77:
      78: # define    USERINGRES  "ingres"
      79:
      80:
      81: /*
      82: **  Structure for 'gtty' and 'stty'
      83: */
      84:
      85: # ifndef xV7_UNIX
      86: struct sgttyb
      87: {
      88:     char    sg_ispeed;
      89:     char    sg_ospeed;
      90:     char    sg_erase;
      91:     char    sg_kill;
      92:     int sg_flags;
      93: };
      94: # endif
      95: # ifdef xV7_UNIX
      96: # include   <sgtty.h>
      97: # endif
      98:
      99:
     100: /*
     101: **  Structure for 'fstat' and 'stat' system calls.
     102: */
     103:
     104: # ifndef xV7_UNIX
     105: struct stat {
     106:     char    st_minor;   /* +0: minor device of i-node */
     107:     char    st_major;   /* +1: major device */
     108:     int st_ino; /* +2 */
     109:     int st_mode;    /* +4: see below */
     110:     char    st_nlinks;  /* +6: number of links to file */
     111:     char    st_uid;     /* +7: user ID of owner */
     112:     char    st_gid;     /* +8: group ID of owner */
     113:     char    st_sz0;     /* +9: high byte of 24-bit size */
     114:     int st_sz1;     /* +10: low word of 24-bit size */
     115:     int st_addr[8]; /* +12: block numbers or device number */
     116:     int st_actime[2];   /* +28: time of last access */
     117:     int st_modtime[2];  /* +32: time of last modification */
     118: };
     119:
     120: #define IALLOC  0100000
     121: #define IFMT    060000
     122: #define     IFDIR   040000
     123: #define     IFCHR   020000
     124: #define     IFBLK   060000
     125: # endif
     126: # ifdef xV7_UNIX
     127: # include   <sys/types.h>
     128: # include   <sys/stat.h>
     129: # endif
     130:
     131:
     132: /*
     133: **  SETEXIT
     134: **	In version 7, setexit is not defined:  this fakes it.
     135: */
     136:
     137: # ifdef xV7_UNIX
     138: # include   <setjmp.h>
     139: # define    setexit()   setjmp(Sx_buf)
     140: extern jmp_buf  Sx_buf;     /* defined in iutil/reset.c */
     141: # endif

#### Defined struct's

sgttyb defined in line 86; never used
stat defined in line 105; never used

#### Defined macros

IALLOC defined in line 120; never used
IFBLK defined in line 124; never used
IFCHR defined in line 123; never used
IFDIR defined in line 122; never used
IFMT defined in line 121; never used
MAXFILES defined in line 68; used 17 times

- in /usr/ingres/source/access/opencatalog.c line 88
- in /usr/ingres/source/dbu/main.c line 83, 172, 312, 355
- in /usr/ingres/source/dbu/modify.c line 616
- in /usr/ingres/source/decomp/call_ovqp.c line 400
- in /usr/ingres/source/decomp/call_ovqp70.c line 439
- in /usr/ingres/source/monitor/edit.c line 42
- in /usr/ingres/source/monitor/main.c line 190
- in /usr/ingres/source/monitor/shell.c line 42
- in /usr/ingres/source/support/ingres.c line 296, 617, 1257, 1483
- in /usr/ingres/source/support/restore.c line 168, 290

USERINGRES defined in line 78; used 4 times

- in /usr/ingres/source/equel/runtime/IIingres.c line 182
- in /usr/ingres/source/iutil/initucode.c line 279
- in /usr/ingres/source/support/usersetup.c line 49, 92

setexit defined in line 139; used 14 times

- in /usr/ingres/source/dbu/main.c line 189
- in /usr/ingres/source/decomp/main.c line 42
- in /usr/ingres/source/iutil/initproc.c line 86
- in /usr/ingres/source/iutil/initucode.c line 242
- in /usr/ingres/source/monitor/main.c line 72, 141-146(2), 160
- in /usr/ingres/source/ovqp/main.c line 31
- in /usr/ingres/source/parser/main.c line 69
- in /usr/ingres/source/qrymod/main.c line 139
- in /usr/ingres/source/support/restore.c line 81, 100, 206

xV7_UNIX defined in line 59; used 31 times

- in line 85, 95, 104, 126, 137
- in /usr/ingres/source/dbu/pr_prot.c line 647-650(2), 656-668(4)
- in /usr/ingres/source/dbu/save.c line 37, 44, 61-64(2), 107-111(2)
- in /usr/ingres/source/iutil/reset.c line 25
- in /usr/ingres/source/qrymod/fillprotup.c line 94-97(2), 103, 109
- in /usr/ingres/source/qrymod/main.c line 81-84(2), 111, 124-129(2)
- in /usr/ingres/source/qrymod/protect.c line 198-201(2), 835, 842

#### Usage of this include

unix.h used 33 times

- in /usr/ingres/source/access/accbuf.c line 5
- in /usr/ingres/source/access/last_page.c line 3
- in /usr/ingres/source/access/opencatalog.c line 3
- in /usr/ingres/source/dbu/main.c line 4
- in /usr/ingres/source/dbu/modify.c line 8
- in /usr/ingres/source/dbu/modupdate.c line 15
- in /usr/ingres/source/dbu/pr_prot.c line 29
- in /usr/ingres/source/dbu/rmqm.c line 49
- in /usr/ingres/source/dbu/save.c line 3
- in /usr/ingres/source/dbu/userdestroy.c line 3
- in /usr/ingres/source/decomp/call_ovqp.c line 4
- in /usr/ingres/source/decomp/call_ovqp70.c line 3
- in /usr/ingres/source/decomp/main.c line 6
- in /usr/ingres/source/equel/display.c line 2
- in /usr/ingres/source/equel/main.c line 6
- in /usr/ingres/source/equel/runtime/IIingres.c line 4
- in /usr/ingres/source/iutil/initproc.c line 3
- in /usr/ingres/source/iutil/initucode.c line 5
- in /usr/ingres/source/iutil/reset.c line 1
- in /usr/ingres/source/monitor/edit.c line 5
- in /usr/ingres/source/monitor/main.c line 5
- in /usr/ingres/source/monitor/shell.c line 5
- in /usr/ingres/source/ovqp/main.c line 3
- in /usr/ingres/source/parser/main.c line 7
- in /usr/ingres/source/parser/master.grammar line 888
- in /usr/ingres/source/qrymod/d_prot.c line 3
- in /usr/ingres/source/qrymod/fillprotup.c line 3
- in /usr/ingres/source/qrymod/main.c line 5
- in /usr/ingres/source/qrymod/protect.c line 3
- in /usr/ingres/source/support/creatdb.c line 8
- in /usr/ingres/source/support/ingres.c line 10
- in /usr/ingres/source/support/restore.c line 6
- in /usr/ingres/source/support/usersetup.c line 5

Last modified: 1995-02-07 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 1448 |