File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / strongswan / m4 / macros / split-package-version.m4
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Wed Jun 3 09:46:49 2020 UTC (4 years, 5 months ago) by misho
Branches: strongswan, MAIN
CVS tags: v5_9_2p0, v5_8_4p7, HEAD
Strongswan

# SPLIT_PACKAGE_VERSION
# ---------------------------
# Split package version in four parts
AC_DEFUN([SPLIT_PACKAGE_VERSION],
	[
	AC_REQUIRE([AC_PROG_SED])
	PACKAGE_VERSION_MAJOR=`echo "$PACKAGE_VERSION" | $SED 's/\([[0-9]]\+\).*/\1/'`
	PACKAGE_VERSION_MINOR=`echo "$PACKAGE_VERSION" | $SED 's/[[0-9]]\+\.\([[0-9]]\+\).*/\1/'`
	PACKAGE_VERSION_BUILD=`echo "$PACKAGE_VERSION" | $SED 's/[[0-9]]\+\.[[0-9]]\+\.\([[0-9]]\+\).*/\1/'`
	PACKAGE_VERSION_REVIEW=`echo "$PACKAGE_VERSION" | $SED 's/[[0-9]]\+\.[[0-9]]\+\.[[0-9]]\+\(.*\)/\1/'`
	AC_SUBST([PACKAGE_VERSION_MAJOR])
	AC_SUBST([PACKAGE_VERSION_MINOR])
	AC_SUBST([PACKAGE_VERSION_BUILD])
	AC_SUBST([PACKAGE_VERSION_REVIEW])
	]
)


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>