* Copyright (c) 1980 The Regents of the University of California.
* This module is believed to contain source code proprietary to AT&T.
* Use and redistribution is subject to the Berkeley Software License
* Agreement and your Software Agreement with AT&T (Western Electric).
"@(#) Copyright (c) 1980 The Regents of the University of California.\n\
static char sccsid
[] = "@(#)mkvers.c 5.2 (Berkeley) 4/12/91";
char id_mkvers
[] = "@(#)mkvers.c 5.2 4/12/91";
* extract sccs id strings from source files
#define VERSION "Version.c"
V
= stdout
; /* fdopen(creat(VERSION, 0644), "w"); */
if (argc
> 1 && argv
[1][0] != '.')
for (s
= argv
[1]; *s
&& *s
!= '.'; s
++)
fprintf(V
, "_id[] = {\n");
fprintf(V
, "char *sccs_id[] = {\n");
fprintf(V
, "\t\"%s%s\t%s\",\n", SCCS_ID
, *++argv
, s
);
if (freopen(*++argv
, "r", stdin
) == NULL
)
if (strncmp(s
, SCCS_ID
, 4) == 0)
fprintf(V
, "\t\"%s\",\n", s
);
fprintf(stderr
, "%s: no sccs id string\n", *argv
);