Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Difference From ce8933afac9b0c71
To 8c205ff00e4ce858
1986-01-11
| | |
11:00 |
|
check-in: 71995845ad user: sam tags: trunk
|
11:00 |
|
check-in: 8c205ff00e user: sam tags: trunk
|
11:00 |
|
check-in: 82e31698f0 user: sam tags: trunk
|
1986-01-03
| | |
23:49 |
|
check-in: c8463e3d46 user: sam tags: trunk
|
23:47 |
|
check-in: ce8933afac user: sam tags: trunk
|
16:27 |
|
check-in: cf01d721a5 user: mckusick tags: trunk
|
| | |
Changes to bin/ps/ps.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
char copyright[] =
"@(#) Copyright (c) 1980 Regents of the University of California.\n\
All rights reserved.\n";
#endif not lint
#ifndef lint
static char sccsid[] = "@(#)ps.c 5.4 (Berkeley) 09/07/85";
static char sccsid[] = "@(#)ps.c 5.5 (Berkeley) 01/10/86";
#endif not lint
#include <stdio.h>
#include <ctype.h>
#include <a.out.h>
#include <pwd.h>
#include <sys/param.h>
|
︙ | | |
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
|
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
|
-
+
|
#ifndef PSFILE
char *psdb = "/etc/psdatabase";
#else
char *psdb = PSFILE;
#endif
int chkpid;
int chkpid = -1;
int aflg, cflg, eflg, gflg, kflg, lflg, nflg, sflg,
uflg, vflg, xflg, Uflg;
int nchans; /* total # of wait channels */
char *tptr;
char *gettty(), *getcmd(), *getname(), *savestr(), *state();
char *rindex(), *calloc(), *sbrk(), *strcpy(), *strcat(), *strncat();
char *strncpy(), *index(), *ttyname(), mytty[MAXPATHLEN+1];
|
︙ | | |
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
|
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
|
-
+
|
mproc->p_pgrp == 0 && xflg == 0)
continue;
if (tptr == 0 && gflg == 0 && xflg == 0 &&
mproc->p_ppid == 1)
continue;
if (uid != mproc->p_uid && aflg==0)
continue;
if (chkpid != 0 && chkpid != mproc->p_pid)
if (chkpid != -1 && chkpid != mproc->p_pid)
continue;
if (vflg && gflg == 0 && xflg == 0) {
if (mproc->p_stat == SZOMB ||
mproc->p_flag&SWEXIT)
continue;
if (mproc->p_slptime > MAXSLP &&
(mproc->p_stat == SSLEEP ||
|
︙ | | |
Changes to bin/rm/rm.c.
1
2
3
4
5
6
7
8
|
1
2
3
4
5
6
7
8
|
-
+
|
static char *sccsid = "@(#)rm.c 4.17 (Berkeley) 11/05/85";
static char *sccsid = "@(#)rm.c 4.18 (Berkeley) 01/06/86";
/*
* rm - for ReMoving files, directories & trees.
*/
#include <stdio.h>
#include <sys/param.h>
|
︙ | | |
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
-
+
|
default:
fprintf(stderr, "usage: rm [-rif] file ...\n");
exit(1);
}
}
if (argc < 2) {
if (argc < 2 && !fflg) {
fprintf(stderr, "usage: rm [-rif] file ...\n");
exit(1);
}
while (--argc > 0)
(void) rm(*++argv, 0);
|
︙ | | |
Changes to bin/stty/stty.1.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
-
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)stty.1 6.2 (Berkeley) 08/13/85
.\" @(#)stty.1 6.3 (Berkeley) 01/09/86
.\"
.TH STTY 1 ""
.UC 4
.SH NAME
stty \- set terminal options
.SH SYNOPSIS
.B stty
[ option ... ]
.SH DESCRIPTION
.I Stty
sets certain I/O options on the current output terminal,
placing its output on the diagnostic output.
With no argument, it reports the speed of the terminal and the
settings of the options which are different from their defaults.
Use of one of the following options modifies the output as described:
.TP 10
.B all
With the argument ``all'', all normally used option settings are reported.
With the argument ``everything'', everything
All normally used option settings are reported.
.TP 10
.B everything
Everything
.I stty
knows about is printed.
.TP 10
.B speed
The terminal speed alone is printed on the standard output.
.TP 10
.B size
The terminal (window) sizes are printed on the standard output,
first rows and then columns.
.sp
The option strings are
selected from the following set:
.TP 10
.B even
allow even parity input
.br
.ns
|
︙ | | |
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
|
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
|
-
+
|
.br
.ns
.TP 10
.BI brk \ c\fR
set break character to
.I c
(default undefined.)
This character is an extra wakeup causing character.
This character is an additional character causing wakeup.
.br
.ns
.TP 10
.B cr0 cr1 cr2 cr3
.br
select style of delay for carriage return (see
.IR ioctl (2))
|
︙ | | |
266
267
268
269
270
271
272
273
274
275
276
277
278
279
|
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
|
+
+
+
+
+
+
+
+
+
|
.br
.ns
.TP 10
.B "50 75 110 134 150 200 300 600 1200 1800 2400 4800 9600 exta extb"
.br
Set terminal baud rate to the number given, if possible.
(These are the speeds supported by the DH-11 interface).
.TP 10
.BI rows \ n\fR
The terminal size is recorded as having
.I n
rows.
.BI columns \ n\fR
The terminal size is recorded as having
.I n
columns.
.PP
A teletype driver which supports the job control processing of
.IR csh (1)
and more functionality than the basic driver is fully described in
.IR tty (4).
The following options apply only to it.
.TP 10
|
︙ | | |
Changes to bin/stty/stty.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
char copyright[] =
"@(#) Copyright (c) 1980 Regents of the University of California.\n\
All rights reserved.\n";
#endif not lint
#ifndef lint
static char sccsid[] = "@(#)stty.c 5.2 (Berkeley) 08/13/85";
static char sccsid[] = "@(#)stty.c 5.3 (Berkeley) 01/09/86";
#endif not lint
/*
* set teletype modes
*/
#include <stdio.h>
|
︙ | | |
282
283
284
285
286
287
288
289
290
291
292
293
294
295
|
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
|
+
+
+
+
+
|
goto done;
win.ws_row = atoi(*++argv);
}
if (eq("columns")) {
if (--argc == 0)
goto done;
win.ws_col = atoi(*++argv);
}
if (eq("size")) {
ioctl(open("/dev/tty", 0), TIOCGWINSZ, &win);
printf("%d %d\n", win.ws_row, win.ws_col);
exit(0);
}
for(i=0; speeds[i].string; i++)
if(eq(speeds[i].string)) {
mode.sg_ispeed = mode.sg_ospeed = speeds[i].speed;
goto cont;
}
if (eq("speed")) {
|
︙ | | |
Changes to games/backgammon/backgammon/Mesgfix.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
+
-
-
-
+
+
+
-
-
-
+
+
+
-
-
-
+
+
+
|
1,5c
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)Mesgfix 5.1 (Berkeley) 05/29/85";
.
/Msccsid/c
static char Msccsid[] = "@(#)Mesgfix 5.2 (Berkeley) 01/08/86";
#endif not lint
4!date
.
/Last update/!date
mark a
g/Sun /s//Sunday, /
g/Mon /s//Monday, /
g/Tue /s//Tuesday, /
g/Wed /s//Wednesday, /
g/Thu /s//Thursday, /
g/Fri /s//Friday, /
g/Sat /s//Saturday, /
g/Jan /s//January /
g/Feb /s//February /
g/Mar /s//March /
g/Apr /s//April /
g/Jun /s//June /
g/Jul /s//July /
g/Aug /s//August /
g/Sep /s//September /
g/Oct /s//October /
g/Nov /s//November /
g/Dec /s//December /
g/ /s// /
4s/ ..:..:.. .../,/
4s/^/ "Last update on /
4s/$/.",/
'as/ ..:..:.. .../,/
'as/^/ "Last update on /
'as/$/.",/
w!
q
|
|
Changes to games/backgammon/common_source/message.c.
1
2
3
4
5
6
7
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
+
+
+
+
+
+
+
+
-
+
+
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char Msccsid[] = "@(#)Mesgfix 5.1 (Berkeley) 5/29/85";
static char sccsid[] = " message.c 4.1 82/05/11 ";
static char sccsid[] = "@(#)message.c 4.2 (Berkeley) 01/08/86";
#endif not lint
char *message[] = {
"Last update on Tuesday, September 16, 1980.",
"Last update on Saturday, March 30, 1985.",
"Check the file /usr/public/gammon.news for details.",
0
};
|
| | | | | | | |
Changes to include/Makefile.
1
2
3
4
5
6
7
8
9
10
11
12
13
|
1
2
3
4
5
6
7
8
9
10
11
12
13
|
-
+
|
#
# Copyright (c) 1980 Regents of the University of California.
# All rights reserved. The Berkeley software License Agreement
# specifies the terms and conditions for redistribution.
#
# @(#)Makefile 5.9 (Berkeley) 85/08/08
# @(#)Makefile 5.10 (Berkeley) 86/01/10
#
# Doing a make install builds /usr/include
#
# Define SHARED to indicate whether you want
# symbolic links to the system source (``symlinks''),
# or a separate copy (``copies'').
# (latter useful in environments where it's
|
︙ | | |
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
-
+
-
+
|
rm -rf ${DESTDIR}/usr/include/$$i; \
ln -s /sys/$$i ${DESTDIR}/usr/include/$$i; \
done
rm -rf ${DESTDIR}/usr/include/sys
ln -s /sys/h ${DESTDIR}/usr/include/sys
copies:
for i in ${SYSDIRS}; do \
-for i in ${SYSDIRS}; do \
rm -rf ${DESTDIR}/usr/include/$$i; \
cd /sys; \
tar cf - $$i/*.h | (cd ${DESTDIR}/usr/include; tar xpfB -); \
done
rm -rf ${DESTDIR}/usr/include/sys;
mkdir ${DESTDIR}/usr/include/sys;
chmod 775 ${DESTDIR}/usr/include/sys;
(cd /sys/h; tar cf - *.h | (cd ${DESTDIR}/usr/include/sys; tar xpfB -))
-(cd /sys/h; tar cf - *.h | (cd ${DESTDIR}/usr/include/sys; tar xpfB -))
tags:
cwd=/usr/include; \
for i in ${STD} ${LINKS}; do \
ctags -a -f ${TAGSFILE} $$cwd/$$i; \
done
clean:
rm -f tags
|
Changes to include/arpa/nameser.h.
1
2
3
4
5
6
7
8
9
10
11
12
13
|
1
2
3
4
5
6
7
8
9
10
11
12
13
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* @(#)nameser.h 5.7 (Berkeley) 11/01/85
* @(#)nameser.h 5.9 (Berkeley) 01/08/86
*/
/*
* Define constants based on rfc883
*/
#define PACKETSZ 512 /* maximum packet size */
#define MAXDNAME 256 /* maximum domain name */
|
︙ | | |
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
-
-
-
-
-
+
+
+
+
+
-
+
+
-
-
-
+
+
+
|
* Currently defined opcodes
*/
#define QUERY 0 /* standard query */
#define IQUERY 1 /* inverse query */
#define CQUERYM 2 /* completion query (multiple) */
#define CQUERYU 3 /* completion query (unique) */
/* non standard */
#define UPDATEA 11 /* add resource record */
#define UPDATED 12 /* delete resource record */
#define UPDATEM 13 /* modify resource record */
#define ZONEINIT 14 /* initial zone transfer */
#define ZONEREF 15 /* incremental zone referesh */
#define UPDATEA 100 /* add resource record */
#define UPDATED 101 /* delete resource record */
#define UPDATEM 102 /* modify resource record */
#define ZONEINIT 103 /* initial zone transfer */
#define ZONEREF 104 /* incremental zone referesh */
/*
* Currently defined response codes
*/
#define NOERROR 0 /* no error */
#define FORMERR 1 /* format error */
#define SERVFAIL 2 /* server failure */
#define NXDOMAIN 3 /* non existent domain */
#define NOTIMP 4 /* not implemented */
#define REFUSED 5 /* query refused */
/* non standard */
#define NOCHANGE 15 /* update failed to change db */
#define NOCHANGE 100 /* update failed to change db */
/*
* Type values for resources and queries
*/
#define T_A 1 /* host address */
#define T_NS 2 /* authoritative server */
#define T_MD 3 /* mail destination */
#define T_MF 4 /* mail forwarder */
#define T_CNAME 5 /* connonical name */
#define T_SOA 6 /* start of authority zone */
#define T_MB 7 /* mailbox domain name */
#define T_MG 8 /* mail group member */
#define T_MR 9 /* mail rename name */
#define T_NULL 10 /* null resource record */
#define T_WKS 11 /* well known service */
#define T_PTR 12 /* domain name pointer */
#define T_HINFO 13 /* host information */
#define T_MINFO 14 /* mailbox information */
#define T_MX 15 /* mail routing information */
/* non standard */
#define T_UINFO 15 /* user (finger) information */
#define T_UID 16 /* user ID */
#define T_GID 17 /* group ID */
#define T_UINFO 100 /* user (finger) information */
#define T_UID 101 /* user ID */
#define T_GID 102 /* group ID */
/* Query type values which do not appear in resource records */
#define T_AXFR 252 /* transfer zone of authority */
#define T_MAILB 253 /* transfer mailbox records */
#define T_MAILA 254 /* transfer mail agent records */
#define T_ANY 255 /* wildcard match */
/*
|
︙ | | |
Changes to lib/libc/compat-43/sigvec.2.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)sigvec.2 6.2 (Berkeley) 06/30/85
.\" @(#)sigvec.2 6.3 (Berkeley) 01/08/86
.\"
.TH SIGVEC 2 ""
.UC 4
.ie t .ds d \(dg
.el .ds d \z'|+'
.ie t .ds b \(bu
.el .ds b @
|
︙ | | |
133
134
135
136
137
138
139
140
141
142
143
144
145
146
|
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
|
+
+
|
SIGTTOU 22\*d background write attempted to control terminal
SIGIO 23\*b i/o is possible on a descriptor (see \fIfcntl\fP(2))
SIGXCPU 24 cpu time limit exceeded (see \fIsetrlimit\fP(2))
SIGXFSZ 25 file size limit exceeded (see \fIsetrlimit\fP(2))
SIGVTALRM 26 virtual time alarm (see \fIsetitimer\fP(2))
SIGPROF 27 profiling timer alarm (see \fIsetitimer\fP(2))
SIGWINCH 28\*b window size change
SIGUSR1 30 user defined signal 1
SIGUSR2 31 user defined signal 2
.fi
.PP
The starred signals in the list above cause a core image
if not caught or ignored.
.PP
Once a signal handler is installed, it remains installed
until another
|
︙ | | |
Changes to lib/libc/gen/setjmp.3.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)setjmp.3 6.1 (Berkeley) 05/15/85
.\" @(#)setjmp.3 6.2 (Berkeley) 01/09/86
.\"
.TH SETJMP 3 ""
.UC 4
.SH NAME
setjmp, longjmp \- non-local goto
.SH SYNOPSIS
.nf
|
︙ | | |
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
|
save and restore the signal mask
.IR sigmask (2),
while
.I _setjmp
and
.I _longjmp
manipulate only the C stack and registers.
.SH ERRORS
.PP
If the contents of the
.B jmp_buf
are corrupted, or correspond to an environment that has already returned,
.I longjmp
calls the routine
.IR longjmperror .
If
.I longjmperror
returns the program is aborted.
The default version of
.I longjmperror
prints the message ``longjmp botch'' to standard error and returns.
User programs wishing to exit more gracefully can write their own
versions of
.IR longjmperror .
.SH "SEE ALSO"
sigvec(2), sigstack(2), signal(3)
.SH BUGS
.I Setjmp
does not save current notion of whether the process is
executing on the signal stack. The result is that a
longjmp to some place on the signal stack leaves the
signal stack state incorrect.
|
Added lib/libc/gen/setjmperr.c.
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)setjmperr.c 5.1 (Berkeley) 01/09/86";
#endif not lint
#define ERRMSG "longjmp botch\n"
/*
* This routine is called from longjmp() when an error occurs.
* Programs that wish to exit gracefully from this error may
* write their own versions.
* If this routine returns, the program is aborted.
*/
longjmperror()
{
write(2, ERRMSG, sizeof(ERRMSG));
}
|
| | | | | | | | | | | | | | | | | | | | | |
Changes to lib/libc/gen/signal.3.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)signal.3 6.2 (Berkeley) 11/06/85
.\" @(#)signal.3 6.3 (Berkeley) 01/08/86
.\"
.TH SIGNAL 3C ""
.UC 4
.ie t .ds d \(dg
.el .ds d \z'|+'
.ie t .ds b \(bu
.el .ds b @
|
︙ | | |
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
-
-
+
+
|
SIGTTOU 22\*d background write attempted to control terminal
SIGIO 23\*b i/o is possible on a descriptor (see \fIfcntl\fP(2))
SIGXCPU 24 cpu time limit exceeded (see \fIsetrlimit\fP(2))
SIGXFSZ 25 file size limit exceeded (see \fIsetrlimit\fP(2))
SIGVTALRM 26 virtual time alarm (see \fIsetitimer\fP(2))
SIGPROF 27 profiling timer alarm (see \fIsetitimer\fP(2))
SIGWINCH 28\*b Window size change
SIGUSR1 30\*b User defined signal 1
SIGUSR2 31\*b User defined signal 2
SIGUSR1 30 User defined signal 1
SIGUSR2 31 User defined signal 2
.fi
.PP
The starred signals in the list above cause a core image
if not caught or ignored.
.PP
If
.I func
|
︙ | | |
Added lib/libc/gen/ualarm.3.
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)@(#)ualarm.3 6.1 (Berkeley) 01/09/86
.\"
.TH UALARM 3 ""
.UC 6
.SH NAME
ualarm \- schedule signal after specified time
.SH SYNOPSIS
.nf
.B ualarm(value, interval)
.B unsigned value;
.B unsigned interval;
.fi
.SH DESCRIPTION
.ft B
This is a simplified interface to setitimer(2).
.ft R
.PP
.I Ualarm
causes signal SIGALRM, see
.IR signal (3C),
to be sent to the invoking process
in a number of microseconds given by the
.I value
argument.
Unless caught or ignored, the signal terminates the process.
.PP
If the
.I interval
argument is non-zero, the SIGALRM signal will be sent
to the process every
.I interval
microseconds after the timer expires (e.g. after
.I value
microseconds have passed).
.PP
Because of scheduling delays,
resumption of execution of when the signal is
caught may be delayed an arbitrary amount.
The longest specifiable delay time (on the vax) is 2147483647 microseconds.
.PP
The return value is the amount of time previously remaining in the alarm clock.
.sh BUGS
This routine is expensive to use because it is implemented using
.IR setitimer (2)
and does eight system calls each time it is invoked.
.SH "SEE ALSO"
getitimer(2), setitimer(2), sigpause(2), sigvec(2), signal(3C), sleep(3),
alarm(3), ualarm(3)
|
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
Added lib/libc/gen/usleep.3.
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)@(#)usleep.3 6.1 (Berkeley) 01/09/86
.\"
.TH USLEEP 3 ""
.UC 6
.SH NAME
usleep \- suspend execution for interval
.SH SYNOPSIS
.nf
.B usleep(useconds)
.B unsigned useconds;
.fi
.SH DESCRIPTION
The current process is suspended from execution for the number
of microseconds specified by the argument.
The actual suspension time may be an arbitrary amount longer
because of other activity in the system.
.PP
The routine is implemented by setting an interval timer
and pausing until it occurs.
The previous state of this timer is saved and restored.
If the sleep time exceeds the time to the expiration of the
previous timer,
the process sleeps only until the signal would have occurred, and the
signal is sent 2 system clock ticks later.
.sh BUGS
This routine is expensive to use because it is implemented using
.IR setitimer (2)
and does eight system calls each time it is invoked.
It should be implemented using
.IR select (2).
.SH "SEE ALSO"
setitimer(2), getitimer(2), sigpause(2), ualarm(3), sleep(3), alarm(3)
|
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
Changes to lib/libc/net/SCCS/hosttable/gethostnamadr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
-
+
+
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)gethostnamadr.c 5.3 (Berkeley) 12/10/85";
static char sccsid[] = "@(#)gethostnamadr.c 5.4 (Berkeley) 01/09/86";
#endif not lint
#include <stdio.h>
#include <netdb.h>
#include <sys/file.h>
#include <ndbm.h>
#include <ctype.h>
#define MAXALIASES 35
static struct hostent host;
static char *host_aliases[MAXALIASES];
static char hostbuf[BUFSIZ+1];
static char *host_addrs[2];
int h_errno;
/*
* The following is shared with gethostent.c
*/
extern char *_host_file;
DBM *_host_db = (DBM *)NULL;
int _host_stayopen; /* set by sethostent(), cleared by endhostent() */
|
︙ | | |
98
99
100
101
102
103
104
105
106
107
108
109
110
111
|
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
+
+
|
key.dptr = lowname;
key.dsize = strlen(lowname);
hp = fetchhost(key);
if (!_host_stayopen) {
dbm_close(_host_db);
_host_db = (DBM *)NULL;
}
if ( hp == NULL)
h_errno = HOST_NOT_FOUND;
return (hp);
}
struct hostent *
gethostbyaddr(addr, length, type)
char *addr;
register int length;
|
︙ | | |
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
|
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
|
+
+
+
+
|
while (hp = gethostent()) {
if (hp->h_addrtype == type && hp->h_length == length
&& bcmp(hp->h_addr, addr, length) == 0)
break;
}
if (!_host_stayopen)
endhostent();
if ( hp == NULL)
h_errno = HOST_NOT_FOUND;
return (hp);
}
key.dptr = addr;
key.dsize = length;
hp = fetchhost(key);
if (!_host_stayopen) {
dbm_close(_host_db);
_host_db = (DBM *)NULL;
}
if ( hp == NULL)
h_errno = HOST_NOT_FOUND;
return (hp);
}
|
Changes to lib/libc/net/res_debug.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1985 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)res_debug.c 5.8 (Berkeley) 12/01/85";
static char sccsid[] = "@(#)res_debug.c 5.9 (Berkeley) 01/08/86";
#endif not lint
#if defined(lint) && !defined(DEBUG)
#define DEBUG
#endif
#include <sys/types.h>
|
︙ | | |
263
264
265
266
267
268
269
270
271
272
273
274
275
276
|
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
|
+
+
+
+
+
+
+
|
fprintf(file,", retry=%ld", getlong(cp));
cp += sizeof(u_long);
fprintf(file,", expire=%ld", getlong(cp));
cp += sizeof(u_long);
fprintf(file,", min=%ld\n", getlong(cp));
cp += sizeof(u_long);
break;
case T_MX:
fprintf(file,"\tname = ");
cp = p_cdname(cp, msg, file);
fprintf(file,", preference = %ld",getlong(cp));
cp += sizeof(u_long);
break;
case T_MINFO:
fprintf(file,"\trequests = ");
cp = p_cdname(cp, msg, file);
fprintf(file,"\n\terrors = ");
cp = p_cdname(cp, msg, file);
break;
|
︙ | | |
341
342
343
344
345
346
347
348
349
350
351
352
353
354
|
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
|
+
+
|
return("CNAME");
case T_SOA: /* start of authority zone */
return("SOA");
case T_MB: /* mailbox domain name */
return("MB");
case T_MG: /* mail group member */
return("MG");
case T_MX: /* mail routing info */
return("MX");
case T_MR: /* mail rename name */
return("MR");
case T_NULL: /* null resource record */
return("NULL");
case T_WKS: /* well known service */
return("WKS");
case T_PTR: /* domain name pointer */
|
︙ | | |
Changes to lib/libc/net/resolver.3.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1985 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)resolver.3 1.2 (Berkeley) 10/30/85
.\" @(#)resolver.3 1.3 (Berkeley) 01/07/86
.\"
.TH RESOLVER 3 "15 November 1985"
.UC 4
.SH NAME
res_mkquery, res_send, res_init, dn_comp, dn_expand \- resolver routines
.SH SYNOPSIS
.B #include <sys/types.h>
|
︙ | | |
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
|
169
170
171
172
173
174
175
176
177
178
|
-
+
-
-
-
-
-
-
-
-
+
|
as the name is compressed.
If
.I dnptr
is NULL, we don't try to compress names. If
.I lastdnptr
is NULL, we don't update the list.
.SH FILES
resolv.conf Contains the default resolver information read by res_init.
/etc/resolv.conf see resolver(5)
There are two types of records in this file, domain and name server.
The domain record specifies the default domain for the resolver to use.
You can have multiple name server records to designate the name servers
addresses you would like the resolver to try. By using this
file you don't have to have a name server actually running on your system
and you can have a back up name server to try in the event your local server
is not responsive.
.SH "SEE ALSO"
named(8), RFC882, RFC883
named(8), resolver(5), RFC882, RFC883
|
Changes to lib/libc/stdlib/malloc.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)malloc.c 5.2 (Berkeley) 10/11/85";
static char sccsid[] = "@(#)malloc.c 5.4 (Berkeley) 01/10/86";
#endif not lint
/*
* malloc.c (Caltech) 2/21/82
* Chris Kingsley, kingsley@cit-20.
*
* This is a very fast storage allocator. It allocates blocks of a small
|
︙ | | |
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
-
+
+
-
-
+
+
|
* nmalloc[i] is the difference between the number of mallocs and frees
* for a given block size.
*/
static u_int nmalloc[NBUCKETS];
#include <stdio.h>
#endif
#ifdef DEBUG
#if defined(DEBUG) || defined(RCHECK)
#define ASSERT(p) if (!(p)) botch("p")
#include <stdio.h>
static
botch(s)
char *s;
{
printf("assertion botched: %s\n", s);
fprintf(stderr, "\r\nassertion botched: %s\r\n", s);
(void) fflush(stderr); /* just in case user buffered it */
abort();
}
#else
#define ASSERT(p)
#endif
char *
|
︙ | | |
142
143
144
145
146
147
148
149
150
151
152
153
154
155
|
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
|
+
+
|
n = -(sizeof (*op) + RSLOP);
} else {
amt = pagesz;
bucket = pagebucket;
}
while (nbytes > amt + n) {
amt <<= 1;
if (amt == 0)
return (NULL);
bucket++;
}
/*
* If nothing in hash bucket right now,
* request more memory from the system.
*/
if ((op = nextf[bucket]) == NULL) {
|
︙ | | |
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
|
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
|
-
-
-
+
+
+
+
+
+
+
+
|
#endif
return ((char *)(op + 1));
}
/*
* Allocate more memory to the indicated bucket.
*/
static
morecore(bucket)
int bucket;
{
register union overhead *op;
register int sz; /* size of desired block */
register int amt; /* amount to allocate */
register int nblks; /* how many blocks we get */
int amt; /* amount to allocate */
int nblks; /* how many blocks we get */
/*
* sbrk_size <= 0 only for big, FLUFFY, requests (about
* 2^30 bytes on a VAX, I think) or for a negative arg.
*/
sz = 1 << (bucket + 3);
if (sz <= 0)
return;
if (sz < pagesz) {
amt = pagesz;
nblks = amt / sz;
} else {
amt = sz + pagesz;
nblks = 1;
}
|
︙ | | |
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
|
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
|
-
+
+
+
+
-
-
+
-
-
-
|
*
* Search for the old block of memory on the
* free list. First, check the most common
* case (last element free'd), then (this failing)
* the last ``realloc_srchlen'' items free'd.
* If all lookups fail, then assume the size of
* the memory block being realloc'd is the
* smallest possible.
* largest possible (so that all "nbytes" of new
* memory are copied into). Note that this could cause
* a memory fault if the old area was tiny, and the moon
* is gibbous. However, that is very unlikely.
*/
if ((i = findbucket(op, 1)) < 0 &&
(i = findbucket(op, realloc_srchlen)) < 0)
#ifndef RCHECK
i = 0;
i = NBUCKETS;
#else
i = 1; /* smallest possible w/ RCHECK */
#endif
}
onb = 1 << (i + 3);
if (onb < pagesz)
onb -= sizeof (*op) + RSLOP;
else
onb += pagesz - sizeof (*op) - RSLOP;
/* avoid the copy if same size block */
|
︙ | | |
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
|
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
|
-
+
|
#endif
return(cp);
} else
free(cp);
}
if ((res = malloc(nbytes)) == NULL)
return (NULL);
if (cp != res) /* common optimization */
if (cp != res) /* common optimization if "compacting" */
bcopy(cp, res, (nbytes < onb) ? nbytes : onb);
return (res);
}
/*
* Search ``srchlen'' elements of each free list for a block whose
* header starts at ``freep''. If srchlen is -1 search the whole list.
|
︙ | | |
Changes to lib/libc/sys/Xsetregid.2.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
-
+
+
+
+
+
-
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)Xsetregid.2 6.1 (Berkeley) 05/15/85
.\" @(#)Xsetregid.2 6.2 (Berkeley) 01/07/86
.\"
.TH SETREGID 2 ""
.UC 5
.SH NAME
setregid \- set real and effective group ID
.SH SYNOPSIS
.nf
.ft B
#include <sys/types.h>
.PP
.ft B
setregid(rgid, egid)
.br
int rgid, egid;
gid_t rgid, egid;
.ft R
.SH DESCRIPTION
The real and effective group ID's of the current process
are set to the arguments.
Unprivileged users may change the real group
ID to the effective group ID and vice-versa; only the super-user may
make other changes.
|
︙ | | |
Changes to lib/libc/sys/getgid.2.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
-
+
+
+
+
+
-
+
-
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)getgid.2 6.1 (Berkeley) 05/15/85
.\" @(#)getgid.2 6.2 (Berkeley) 01/07/86
.\"
.TH GETGID 2 ""
.UC 5
.SH NAME
getgid, getegid \- get group identity
.SH SYNOPSIS
.nf
.ft B
#include <sys/types.h>
.PP
.nf
.ft B
gid = getgid()
int gid;
gid_t gid;
.PP
.ft B
egid = getegid()
int egid;
gid_t egid;
.fi
.SH DESCRIPTION
.I Getgid
returns the real group ID of the current process,
.I getegid
the effective group ID.
.PP
|
︙ | | |
Changes to lib/libc/sys/getuid.2.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
-
+
+
+
+
+
-
+
-
+
|
.\" Copyright (c) 1980 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)getuid.2 6.2 (Berkeley) 06/28/85
.\" @(#)getuid.2 6.3 (Berkeley) 01/07/86
.\"
.TH GETUID 2 ""
.UC 4
.SH NAME
getuid, geteuid \- get user identity
.SH SYNOPSIS
.nf
.ft B
#include <sys/types.h>
.PP
.ft B
.nf
uid = getuid()
int uid;
uid_t uid;
.PP
.ft B
euid = geteuid()
int euid;
uid_t euid;
.fi
.SH DESCRIPTION
.I Getuid
returns the real user ID of the current process,
.I geteuid
the effective user ID.
.PP
|
︙ | | |
Changes to lib/libc/sys/setuid.2.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
-
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
-
-
-
+
+
+
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)setuid.2 6.1 (Berkeley) 05/15/85
.\" @(#)setuid.2 6.2 (Berkeley) 01/07/86
.\"
.TH SETUID 3 ""
.UC 5
.SH NAME
setuid, seteuid, setruid, setgid, setegid, setrgid \- set user and group ID
.SH SYNOPSIS
.nf
.ft B
#include <sys/types.h>
.PP
.ft B
.nf
.B setuid(uid)
.B seteuid(euid)
.B setruid(ruid)
setuid(uid)
seteuid(euid)
setruid(ruid)
uid_t uid, euid, ruid;
.PP
.ft B
.nf
.B setgid(gid)
.B setegid(egid)
.B setrgid(rgid)
setgid(gid)
setegid(egid)
setrgid(rgid)
gid_t gid, egid, rgid;
.fi
.SH DESCRIPTION
.I Setuid
.RI ( setgid )
sets both the real and effective
user ID (group ID) of the current process to
as specified.
|
︙ | | |
Changes to lib/libc/sys/socket.2.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)socket.2 6.2 (Berkeley) 06/30/85
.\" @(#)socket.2 6.3 (Berkeley) 01/07/86
.\"
.TH SOCKET 2 ""
.UC 5
.SH NAME
socket \- create an endpoint for communication
.SH SYNOPSIS
.nf
|
︙ | | |
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
-
+
|
The currently understood formats are
.PP
.RS
.nf
.ta 1.25i 1.75i
AF_UNIX (UNIX path names),
AF_INET (ARPA Internet addresses),
AF_PUP (Xerox PUP-I Internet addresses), and
AF_NS (Xerox Network Systems addresses), and
AF_IMPLINK (IMP \*(lqhost at IMP\*(rq addresses).
.fi
.RE
.PP
The socket has the indicated
.I type,
which specifies the semantics of communication. Currently
|
︙ | | |
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
|
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
+
+
+
+
+
+
-
+
|
.PP
A SOCK_STREAM type provides sequenced, reliable,
two-way connection based byte streams with an out-of-band data
transmission mechanism.
A SOCK_DGRAM socket supports
datagrams (connectionless, unreliable messages of
a fixed (typically small) maximum length).
A SOCK_SEQPACKET socket may provide a sequenced, reliable,
two-way connection-based data transmission path for datagrams
of fixed maximum length; a consumer may be required to read
an entire packet with each read system call.
This facility is protocol specific, and presently implemented
only for AF_NS.
SOCK_RAW sockets provide access to internal network interfaces.
The types SOCK_RAW,
which is available only to the super-user, and
SOCK_SEQPACKET and SOCK_RDM, which are planned,
SOCK_RDM, which is planned,
but not yet implemented, are not described here.
.PP
The
.I protocol
specifies a particular protocol to be used with the socket.
Normally only a single protocol exists to support a particular
socket type using a given address format. However, it is possible
|
︙ | | |
118
119
120
121
122
123
124
125
126
127
128
129
130
131
|
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
|
+
+
+
+
+
+
+
|
An error is then indicated if no response can be
elicited on an otherwise
idle connection for a extended period (e.g. 5 minutes).
A SIGPIPE signal is raised if a process sends
on a broken stream; this causes naive processes,
which do not handle the signal, to exit.
.PP
SOCK_SEQPACKET sockets employ the same system calls
as SOCK_STREAM sockets. The only difference
is that
.IR read (2)
calls will return only the amount of data requested,
and any remaining in the arriving packet will be discarded.
.PP
SOCK_DGRAM and SOCK_RAW
sockets allow sending of datagrams to correspondents
named in
.IR send (2)
calls. It is also possible to receive datagrams at
such a socket with
.IR recv (2).
|
︙ | | |
Changes to lib/libc/vax/gen/_setjmp.s.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
.asciz "@(#)_setjmp.s 5.2 (Berkeley) 06/05/85"
.asciz "@(#)_setjmp.s 5.3 (Berkeley) 01/09/86"
#endif not lint
/*
* C library -- _setjmp, _longjmp
*
* _longjmp(a,v)
|
︙ | | |
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
64
65
66
67
68
69
70
71
72
|
-
-
-
-
+
-
-
-
-
-
|
ret # unwind stack before signals enabled
3:
addl2 $8,sp # compensate for PSL-PC push
4:
jmp *4(r1) # done, return....
botch:
pushl $msgend-msg
pushl $msg
pushl $2
calls $3,_write
calls $0,_longjmperror
halt
.data
msg: .ascii "_longjmp botch\n"
msgend:
reiins: rei
|
Changes to lib/libc/vax/gen/setjmp.s.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
.asciz "@(#)setjmp.s 5.3 (Berkeley) 08/16/85"
.asciz "@(#)setjmp.s 5.4 (Berkeley) 01/09/86"
#endif not lint
/*
* C library -- setjmp, longjmp
*
* longjmp(a,v)
* will generate a "return(v)" from
|
︙ | | |
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
83
84
85
86
87
88
89
90
91
|
-
-
-
-
+
-
-
-
-
|
4:
#endif NOCOMPAT
pushl r1 # pointer to sigcontext
calls $1,_sigreturn # restore previous context
# we should never return
botch:
pushl $msgend-msg
pushl $msg
pushl $2
calls $3,_write
calls $0,_longjmperror
halt
.data
msg: .ascii "longjmp botch\n"
msgend:
|
Changes to libexec/getty/gettytab.5.
1
2
3
4
5
6
7
8
9
10
11
12
|
1
2
3
4
5
6
7
8
9
10
11
12
|
-
+
|
.\" Copyright (c) 1983 Regents of the University of California.
.\" All rights reserved. The Berkeley software License Agreement
.\" specifies the terms and conditions for redistribution.
.\"
.\" @(#)gettytab.5 6.1 (Berkeley) 05/15/85
.\" @(#)gettytab.5 6.2 (Berkeley) 01/07/86
.\"
.TH GETTYTAB 5 ""
.UC 5
.SH NAME
gettytab \- terminal configuration data base
.SH SYNOPSIS
/etc/gettytab
|
︙ | | |
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
+
|
cb bool false use crt backspace mode
cd num 0 carriage-return delay
ce bool false use crt erase algorithm
ck bool false use crt kill algorithm
cl str NULL screen clear sequence
co bool false console - add \\n after login prompt
ds str ^Y delayed suspend character
dx bool false set DECCTLQ
ec bool false leave echo \s-2OFF\s0
ep bool false terminal uses even parity
er str ^? erase character
et str ^D end of text (\s-2EOF\s0) character
ev str NULL initial enviroment
f0 num unused tty mode flags to write messages
f1 num unused tty mode flags to read login name
|
︙ | | |
Changes to libexec/getty/gettytab.h.
1
2
3
4
5
6
7
8
9
10
11
12
13
|
1
2
3
4
5
6
7
8
9
10
11
12
13
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*
* @(#)gettytab.h 5.1 (Berkeley) 04/29/85
* @(#)gettytab.h 5.2 (Berkeley) 01/07/86
*/
/*
* Getty description definitions.
*/
struct gettystrs {
char *field; /* name to lookup in gettytab */
|
︙ | | |
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
|
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
+
|
#define LC gettyflags[13].value
#define UC gettyflags[14].value
#define IG gettyflags[15].value
#define PS gettyflags[16].value
#define HC gettyflags[17].value
#define UB gettyflags[18].value
#define AB gettyflags[19].value
#define DX gettyflags[20].value
int getent();
long getnum();
int getflag();
char *getstr();
extern struct gettyflags gettyflags[];
extern struct gettynums gettynums[];
extern struct gettystrs gettystrs[];
extern int hopcount;
|
Changes to libexec/getty/init.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)init.c 5.1 (Berkeley) 04/29/85";
static char sccsid[] = "@(#)init.c 5.2 (Berkeley) 01/07/86";
#endif not lint
/*
* Getty table initializations.
*
* Melbourne getty.
*/
|
︙ | | |
83
84
85
86
87
88
89
90
91
|
83
84
85
86
87
88
89
90
91
92
|
+
|
{ "lc", 0 }, /* terminal las lower case */
{ "uc", 0 }, /* terminal has no lower case */
{ "ig", 0 }, /* ignore garbage */
{ "ps", 0 }, /* do port selector speed select */
{ "hc", 1 }, /* don't set hangup on close */
{ "ub", 0 }, /* unbuffered output */
{ "ab", 0 }, /* auto-baud detect with '\r' */
{ "dx", 0 }, /* set decctlq */
{ 0 }
};
|
Changes to libexec/getty/subr.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)subr.c 5.3 (Berkeley) 10/18/85";
static char sccsid[] = "@(#)subr.c 5.4 (Berkeley) 01/07/86";
#endif not lint
/*
* Melbourne getty.
*/
#include <sgtty.h>
#include "gettytab.h"
|
︙ | | |
185
186
187
188
189
190
191
192
193
194
195
196
197
198
|
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
|
+
+
+
|
if (EC)
f |= ECHO;
if (XC)
f |= CTLECH;
if (DX)
f |= DECCTQ;
return (f);
}
struct delayval {
unsigned delay; /* delay in ms */
int bits;
};
|
︙ | | |
Changes to libexec/rlogind/rlogind.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
char copyright[] =
"@(#) Copyright (c) 1983 Regents of the University of California.\n\
All rights reserved.\n";
#endif not lint
#ifndef lint
static char sccsid[] = "@(#)rlogind.c 5.9 (Berkeley) 11/08/85";
static char sccsid[] = "@(#)rlogind.c 5.10 (Berkeley) 01/07/86";
#endif not lint
/*
* remote login server:
* remuser\0
* locuser\0
* terminal info\0
|
︙ | | |
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
|
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
|
+
-
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
|
*/
protocol(f, p)
int f, p;
{
char pibuf[1024], fibuf[1024], *pbp, *fbp;
register pcc = 0, fcc = 0;
int cc;
char cntl;
/*
* Must ignore SIGTTOU, otherwise we'll stop
* when we try and set slave pty's window shape
* (our controlling tty is the master pty).
*/
(void) signal(SIGTTOU, SIG_IGN);
send(f, oobdata, 1, MSG_OOB); /* indicate new rlogin */
for (;;) {
int ibits = 0, obits = 0;
int ibits, obits, ebits;
ibits = 0;
obits = 0;
if (fcc)
obits |= (1<<p);
else
ibits |= (1<<f);
if (pcc >= 0)
if (pcc)
obits |= (1<<f);
else
ibits |= (1<<p);
ebits = (1<<p);
if (select(16, &ibits, &obits, 0, 0) < 0) {
if (select(16, &ibits, &obits, &ebits, 0) < 0) {
if (errno == EINTR)
continue;
fatalperror(f, "select", errno);
}
if (ibits == 0 && obits == 0) {
if (ibits == 0 && obits == 0 && ebits == 0) {
/* shouldn't happen... */
sleep(5);
continue;
}
#define pkcontrol(c) ((c)&(TIOCPKT_FLUSHWRITE|TIOCPKT_NOSTOP|TIOCPKT_DOSTOP))
if (ebits & (1<<p)) {
cc = read(p, &cntl, 1);
if (cc == 1 && pkcontrol(cntl)) {
cntl |= oobdata[0];
send(f, &cntl, 1, MSG_OOB);
if (cntl & TIOCPKT_FLUSHWRITE) {
pcc = 0;
ibits &= ~(1<<p);
}
}
}
if (ibits & (1<<f)) {
fcc = read(f, fibuf, sizeof (fibuf));
if (fcc < 0 && errno == EWOULDBLOCK)
fcc = 0;
else {
register char *cp;
|
︙ | | |
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
|
288
289
290
291
292
293
294
295
296
297
298
299
300
301
|
-
|
if (pcc < 0 && errno == EWOULDBLOCK)
pcc = 0;
else if (pcc <= 0)
break;
else if (pibuf[0] == 0)
pbp++, pcc--;
else {
#define pkcontrol(c) ((c)&(TIOCPKT_FLUSHWRITE|TIOCPKT_NOSTOP|TIOCPKT_DOSTOP))
if (pkcontrol(pibuf[0])) {
pibuf[0] |= oobdata[0];
send(f, &pibuf[0], 1, MSG_OOB);
}
pcc = 0;
}
}
|
︙ | | |
Changes to local/ditroff/ditroff.old.okeeffe/driver/ifontinfo.c.
1
2
3
4
5
6
7
8
|
1
2
3
4
5
6
7
8
|
-
+
|
static char sccsid[] = "ifontinfo.c 1.5 (Berkeley) 85/02/26";
static char sccsid[] = "ifontinfo.c 1.6 (Berkeley) 86/01/05";
/* Font Information for Imagen-style fonts (RST format)
* taken from vfontinfo, by Andy Hertzfeld 4/79
*/
#include <stdio.h>
#include <ctype.h>
|
︙ | | |
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
98
99
100
101
102
103
104
105
106
107
108
109
110
111
|
-
-
|
p.p_linesp = rd4();
p.p_wordsp = rd4();
p.p_rot = rd2();
p.p_cadv = rd1();
p.p_ladv = rd1();
p.p_id = rd4();
p.p_res = rd2();
if (p.p_res != RES)
error("wrong resolution in Font file.");
i = p.p_glyph - 44;
idstrings = (char *) malloc (i);
endstring = idstrings;
while (i--) if ((*(endstring++) = getc(FID)) == EOF)
error("bad preamble in Font file.");
|
︙ | | |
Changes to local/tac/tac.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
-
+
-
-
+
+
+
|
#ifndef lint
static char sccsid[] = "@(#)tac.c 1.1 06/09/85";
static char sccsid[] = "@(#)tac.c 1.2 01/11/86";
#endif
/*
* tac.c - Print file segments in reverse order
*
* Original line-only version by unknown author off the net.
* 1985 mods by Jay Lepreau, Univ of Utah, to allocate memory dynamically
* and handle string bounded segments.
* 1985 mods by Jay Lepreau, Univ of Utah, to allocate memory
* dynamically and handle string bounded segments (latter idea
* suggested by Rob Pike).
*/
#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
/*
|
︙ | | |
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
-
+
|
/*
* Arrange for the first read to lop off enough to
* leave the rest of the file a multiple of readsize.
* Since readsize can change, this may not always hold during
* the pgm run, but since it usually will, leave it here
* for i/o efficiency (page/sector boundaries and all that).
* Note: Above statement has never been verified!
* Note: the efficiency gain has never been verified...
*/
if ((i = off % readsize) == 0)
i = readsize;
off -= i;
(void) lseek(fd, off, 0);
if (read(fd, buf, i) != i) {
|
︙ | | |
Changes to old/dbx/check.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)check.c 5.1 (Berkeley) 05/31/85";
static char sccsid[] = "@(#)check.c 5.2 (Berkeley) 01/10/86";
#endif not lint
static char rcsid[] = "$Header: check.c,v 1.5 84/12/26 10:38:35 linton Exp $";
/*
* Check a tree for semantic correctness.
*/
|
︙ | | |
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
+
+
+
+
-
+
|
Symbol f;
checkref(p);
switch (p->op) {
case O_ASSIGN:
p1 = p->value.arg[0];
p2 = p->value.arg[1];
if (varIsSet("$unsafeassign")) {
if (size(p1->nodetype) != size(p2->nodetype)) {
error("incompatible sizes");
}
if (not compatible(p1->nodetype, p2->nodetype)) {
} else if (not compatible(p1->nodetype, p2->nodetype)) {
error("incompatible types");
}
break;
case O_CATCH:
case O_IGNORE:
if (p->value.lcon < 0 or p->value.lcon > NSIG) {
|
︙ | | |
Changes to old/dbx/fortran.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)fortran.c 5.2 (Berkeley) 09/05/85";
static char sccsid[] = "@(#)fortran.c 5.3 (Berkeley) 01/10/86";
#endif not lint
static char rcsid[] = "$Header: fortran.c,v 1.5 84/12/26 10:39:37 linton Exp $";
/*
* FORTRAN dependent symbol routines.
*/
|
︙ | | |
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
-
+
|
#include "eval.h"
#include "operators.h"
#include "mappings.h"
#include "process.h"
#include "runtime.h"
#include "machine.h"
#define isfloat(range) ( \
#define isspecial(range) ( \
range->symvalue.rangev.upper == 0 and range->symvalue.rangev.lower > 0 \
)
#define isrange(t, name) (t->class == RANGE and istypename(t->type, name))
#define MAXDIM 20
|
︙ | | |
176
177
178
179
180
181
182
183
184
185
186
187
188
189
|
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
|
+
|
Symbol eltype;
switch (s->class) {
case CONST:
printf("parameter %s = ", symname(s));
eval(s->symvalue.constval);
printval(s);
break;
case REF:
printf(" (dummy argument) ");
case VAR:
|
︙ | | |
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
|
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
|
-
+
+
+
+
+
+
+
+
+
+
-
+
+
-
+
|
printf("\"%.*s\"", len, sp);
} else {
fortran_printarray(s);
}
break;
case RANGE:
if (isfloat(s)) {
if (isspecial(s)) {
switch (s->symvalue.rangev.lower) {
case sizeof(short):
if (istypename(s->type, "logical*2")) {
printlogical(pop(short));
}
break;
case sizeof(float):
if (istypename(s->type, "logical")) {
printlogical(pop(long));
} else {
prtreal(pop(float));
prtreal(pop(float));
}
break;
case sizeof(double):
if (istypename(s->type,"complex")) {
if (istypename(s->type, "complex")) {
d2 = pop(float);
d1 = pop(float);
printf("(");
prtreal(d1);
printf(",");
prtreal(d2);
printf(")");
|
︙ | | |
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
|
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
|
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
+
-
+
|
prtreal(d1);
printf(",");
prtreal(d2);
printf(")");
break;
default:
panic("bad size \"%d\" for real",
panic("bad size \"%d\" for special",
s->symvalue.rangev.lower);
break;
}
} else {
printint(popsmall(s), s);
}
break;
default:
if (ord(s->class) > ord(TYPEREF)) {
panic("printval: bad class %d", ord(s->class));
}
error("don't know how to print a %s", fortran_classname(s));
/* NOTREACHED */
}
}
/*
* Print out a logical
*/
private printlogical(i)
Integer i;
{
if (i == 0) {
printf(".false.");
} else {
printf(".true.");
}
}
/*
* Print out an int
*/
private printint(i, t)
Integer i;
register Symbol t;
{
if (istypename(t->type, "logical")) {
printf(((Boolean) i) == true ? "true" : "false");
}
else if ( (t->type == t_int) or istypename(t->type, "integer") or
if ( (t->type == t_int) or istypename(t->type, "integer") or
istypename(t->type,"integer*2") ) {
printf("%ld", i);
} else if (istypename(t->type, "addr")) {
printf("0x%lx", i);
} else {
error("unkown type in fortran printint");
error("unknown type in fortran printint");
}
}
/*
* Print out a null-terminated string (pointer to char)
* starting at the given address.
*/
|
︙ | | |
Changes to old/dbx/runtime.c.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
-
+
|
/*
* Copyright (c) 1983 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
#ifndef lint
static char sccsid[] = "@(#)runtime.c 5.1 (Berkeley) 05/31/85";
static char sccsid[] = "@(#)runtime.c 5.2 (Berkeley) 01/10/86";
#endif not lint
static char rcsid[] = "$Header: runtime.c,v 1.5 84/12/26 10:41:52 linton Exp $";
/*
* Runtime organization dependent routines, mostly dealing with
* activation records.
|
︙ | | |
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
|
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
|
+
+
+
-
+
+
|
Symbol proc;
Node arglist;
{
Stack *savesp;
int argc, args_size;
savesp = sp;
if (varIsSet("$unsafecall")) {
argc = unsafe_evalargs(proc, arglist);
} else {
argc = evalargs(proc, arglist);
argc = evalargs(proc, arglist);
}
args_size = sp - savesp;
setreg(STKP, reg(STKP) - args_size);
dwrite(savesp, reg(STKP), args_size);
sp = savesp;
return argc;
}
|
︙ | | |
944
945
946
947
948
949
950
951
952
953
954
955
956
957
|
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
++count;
}
if (chk) {
if (formal != nil) {
sp = savesp;
error("not enough parameters to %s", symname(proc));
}
}
return count;
}
/*
* Evaluate an argument list without concern for matching the formal
* parameters of a function in type or quantity. Useful for functions
* like C's printf().
*/
private integer unsafe_evalargs(proc, arglist)
Symbol proc;
Node arglist;
{
Node p;
Integer count;
count = 0;
for (p = arglist; p != nil; p = p->value.arg[1]) {
assert(p->op == O_COMMA);
eval(p->value.arg[0]);
++count;
}
return count;
}
public procreturn(f)
Symbol f;
{
|
︙ | | |
Changes to old/make/files.c.
1
2
3
4
5
6
7
8
|
1
2
3
4
5
6
7
8
|
-
+
|
static char *sccsid = "@(#)files.c 4.11 (Berkeley) 85/08/30";
static char *sccsid = "@(#)files.c 4.12 (Berkeley) 86/01/09";
#include <fcntl.h>
/* UNIX DEPENDENT PROCEDURES */
/* DEFAULT RULES FOR UNIX */
|
︙ | | |
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
|
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
|
-
+
|
dirpref = "";
filepat = pat;
cp = varptr("VPATH");
if (*cp->varval == 0) path = ".";
else {
path = pth;
*path = '\0';
if (*cp->varval != '.') strcpy(pth,".:");
if (strncmp(cp->varval, ".:", 2) != 0) strcpy(pth,".:");
strcat(pth, cp->varval);
}
}
else {
*endir = '\0';
path = strcpy(pth, pat);
dirpref = concat(pat, "/", temp);
|
︙ | | |
Changes to old/make/main.c.
1
2
3
4
5
6
7
8
|
1
2
3
4
5
6
7
8
|
-
+
|
static char *sccsid = "@(#)main.c 4.7 (Berkeley) 85/08/30";
static char *sccsid = "@(#)main.c 4.8 (Berkeley) 86/01/09";
# include "defs"
/*
command make to update programs.
Flags: 'd' print out debugging comments
'p' print out a version of the input graph
's' silent mode--don't print out commands
'f' the next argument is the name of the description file;
|
︙ | | |
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
|
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
|
-
+
|
fin = k;
yylineno = 0;
zznextc = 0;
if( yyparse() )
fatal("Description file error");
if(fin != NULL)
if(fin != NULL && fin != stdin)
fclose(fin);
return(0);
}
printdesc(prntflag)
int prntflag;
|
︙ | | |
Changes to old/pcc/c2.vax/c21.c.
1
2
3
4
5
6
7
8
9
|
1
2
3
4
5
6
7
8
9
|
-
+
|
#ifndef lint
static char sccsid[] = "@(#)c21.c 4.16 08/22/85";
static char sccsid[] = "@(#)c21.c 4.17 01/08/86";
#endif
/* char C21[] = {"@(#)c21.c 1.83 80/10/16 21:18:22 JFR"}; /* sccs ident */
/*
* C object code improver-- second part
*/
|
︙ | | |
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
|
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
|
-
-
+
+
|
switch (shcnt)
{
case 1: pf->subop = WORD; break;
case 2: pf->subop = LONG; break;
case 3: pf->subop = QUAD; break;
}
redunm++; nsaddr++; nchange++;
}
goto std;
goto std;
}
ashadd:
/* at this point, RT2 and RT3 are guaranteed to be simple regs*/
if (shcnt == 1 && equstr(regs[RT2], regs[RT3]))
{
/*
** quickie:
** ashl $1,A,A > addl2 A,A
|
︙ | | |
Added old/pcc/ccom.tahoe/Makefile.
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
|
# Makefile 1.1 86/01/11
#
# Makefile for portable c compiler
#
DESTDIR=
M= ../mip.tahoe
CFLAGS= -O -I${M} -I.
OBJS= rodata.o cgram.o xdefs.o scan.o pftn.o trees.o optim.o code.o local.o \
reader.o local2.o order.o match.o allo.o comm1.o table.o stab.o
all: ccom alist
ccom: ${OBJS}
$(CC) $(LDFLAGS) ${OBJS} -o ccom
alist: alist.c
$(CC) -o alist $(CFLAGS) alist.c
trees.o: $M/manifest macdefs $M/mfile1 $M/trees.c
$(CC) -c $(CFLAGS) $M/trees.c
optim.o: $M/manifest macdefs $M/mfile1 $M/optim.c
$(CC) -c $(CFLAGS) $M/optim.c
pftn.o: $M/manifest macdefs $M/mfile1 $M/pftn.c
$(CC) -c $(CFLAGS) $M/pftn.c
code.o: $M/manifest macdefs $M/mfile1
$(CC) -c $(CFLAGS) code.c
local.o: $M/manifest macdefs $M/mfile1
$(CC) -c $(CFLAGS) local.c
stab.o: $M/manifest macdefs $M/mfile1
$(CC) -c $(CFLAGS) stab.c
scan.o: $M/manifest macdefs $M/mfile1 $M/scan.c
$(CC) -c $(CFLAGS) $M/scan.c
xdefs.o: $M/manifest $M/mfile1 macdefs $M/xdefs.c
$(CC) -c $(CFLAGS) $M/xdefs.c
cgram.o: $M/manifest $M/mfile1 macdefs cgram.c
$(CC) -c $(CFLAGS) cgram.c
rodata.o: rodata.c
$(CC) -c $(CFLAGS) -R rodata.c
rodata.c cgram.c: $M/cgram.y
$(YACC) $M/cgram.y
rm -f rodata.c
./:yyfix yyexca yyact yypact yypgo yyr1 yyr2 yychk yydef
mv y.tab.c cgram.c
comm1.o: $M/manifest $M/mfile1 $M/common macdefs $M/comm1.c
$(CC) -c $(CFLAGS) $M/comm1.c
table.o: $M/manifest $M/mfile2 mac2defs macdefs table.c
$(CC) -c $(CFLAGS) -R table.c
reader.o: $M/manifest $M/mfile2 mac2defs macdefs $M/reader.c
$(CC) -c $(CFLAGS) $M/reader.c
local2.o: $M/manifest $M/mfile2 mac2defs macdefs
$(CC) -c $(CFLAGS) local2.c
order.o: $M/manifest $M/mfile2 mac2defs macdefs
$(CC) -c $(CFLAGS) order.c
match.o: $M/manifest $M/mfile2 mac2defs macdefs $M/match.c
$(CC) -c $(CFLAGS) $M/match.c
allo.o: $M/manifest $M/mfile2 mac2defs macdefs $M/allo.c
$(CC) -c $(CFLAGS) $M/allo.c
clean:
rm -f *.o ccom cgram.c rodata.c
lintall:
lint -hv -I. -I$M $(CFLAGS) rodata.c cgram.c $M/xdefs.c \
$M/scan.c $M/pftn.c $M/trees.c $M/optim.c code.c local.c \
$M/reader.c local2.c order.c $M/match.c $M/allo.c $M/comm1.c table.c
install: all
-mv ${DESTDIR}/lib/ccom ${DESTDIR}/lib/ccom.old
install -s ccom ${DESTDIR}/lib/ccom
install -s alist ${DESTDIR}/lib/alist
|
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
Added old/pcc/ccom.tahoe/code.c.