1*48112Sbostic /*- 2*48112Sbostic * Copyright (c) 1980 The Regents of the University of California. 3*48112Sbostic * All rights reserved. 4*48112Sbostic * 5*48112Sbostic * %sccs.include.redist.c% 622242Sdist */ 77744Speter 822242Sdist #ifndef lint 922242Sdist char copyright[] = 10*48112Sbostic "@(#) Copyright (c) 1980 The Regents of the University of California.\n\ 1122242Sdist All rights reserved.\n"; 12*48112Sbostic #endif /* not lint */ 1322242Sdist 1422242Sdist #ifndef lint 15*48112Sbostic static char sccsid[] = "@(#)version.c 5.3 (Berkeley) 04/16/91"; 16*48112Sbostic #endif /* not lint */ 1722242Sdist 1816275Speter #include <sys/time.h> 197744Speter #include <stdio.h> 207744Speter 217744Speter extern char version[]; 227744Speter 237744Speter main() 247744Speter { 257744Speter long time(); 267744Speter long clock; 277744Speter struct tm *localtime(); 287744Speter struct tm *tmp; 297744Speter int major; 307744Speter int minor; 317744Speter 327744Speter time(&clock); 337744Speter tmp = localtime(&clock); 347744Speter sscanf(version, "%d.%d", &major, &minor); 357744Speter minor += 1; 367744Speter printf("char version[] = \"%d.%d (%d/%d/%d)\";\n", 377744Speter major, minor, tmp->tm_mon+1, tmp->tm_mday, tmp->tm_year); 3844351Sbostic exit(0); 397744Speter } 40