xref: /freebsd/usr.bin/lex/version.awk (revision 7d99ab9fd0cc2c1ce2ecef0ed6d0672c2a50b0cb)
1# $FreeBSD$
2
3BEGIN {
4	FS = "[ \t\.\"]+"
5}
6
7{
8	if ($1 ~ /^#define$/ && $2 ~ /^VERSION$/) {
9		printf("-DFLEX_MAJOR_VERSION=%s\n", $3);
10		printf("-DFLEX_MINOR_VERSION=%s\n", $4);
11		printf("-DFLEX_SUBMINOR_VERSION=%s\n", $5);
12	}
13}
14