config root man

Current Path : /usr/src/share/examples/FreeBSD_version/

FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64
Upload File :
Current File : //usr/src/share/examples/FreeBSD_version/FreeBSD_version.c

/* $FreeBSD: release/9.1.0/share/examples/FreeBSD_version/FreeBSD_version.c 183495 2008-09-30 11:25:55Z kib $ */
#if __FreeBSD__ == 0		/* 1.0 did not define __FreeBSD__ */
#define __FreeBSD_version 199401
#elif __FreeBSD__ == 1		/* 1.1 defined it to be 1 */
#define __FreeBSD_version 199405
#else				/* 2.0 and higher define it to be 2 */
#include <osreldate.h>		/* and this works */
#endif
#include <stdio.h>
#include <unistd.h>

int
main(void) {
	printf("Compilation release date: %d\n", __FreeBSD_version);
#if __FreeBSD_version >= 199408
	printf("Execution environment release date: %d\n", getosreldate());
#else
	printf("Execution environment release date: can't tell\n");
#endif
	return (0);
}

Man Man