2016-01-04 21:43:19 +03:00
|
|
|
dnl @synopsis mc_VERSION
|
2009-06-02 17:36:58 +04:00
|
|
|
dnl
|
2009-12-29 19:23:29 +03:00
|
|
|
dnl Get current version of Midnight Commander from git tags
|
2009-06-02 17:36:58 +04:00
|
|
|
dnl
|
|
|
|
dnl @author Slava Zanko <slavazanko@gmail.com>
|
2021-04-04 10:12:00 +03:00
|
|
|
dnl @version 2021-04-04
|
2009-06-02 17:36:58 +04:00
|
|
|
dnl @license GPL
|
|
|
|
dnl @copyright Free Software Foundation, Inc.
|
2021-03-13 12:12:40 +03:00
|
|
|
dnl @modified Andrew Borodin <aborodin@vmail.ru>
|
2009-06-02 17:36:58 +04:00
|
|
|
|
2016-01-04 21:43:19 +03:00
|
|
|
AC_DEFUN([mc_VERSION],[
|
2021-03-18 15:25:06 +03:00
|
|
|
if test -f ${srcdir}/mc-version.h; then
|
|
|
|
VERSION=$(grep '^#define MC_CURRENT_VERSION' ${srcdir}/mc-version.h | sed 's/.*"\(.*\)"$/\1/')
|
2009-06-02 17:36:58 +04:00
|
|
|
else
|
|
|
|
VERSION="unknown"
|
|
|
|
fi
|
2009-12-29 19:23:29 +03:00
|
|
|
|
2021-03-13 12:12:40 +03:00
|
|
|
dnl Version without dashes for the man page
|
2021-04-04 10:12:00 +03:00
|
|
|
MAN_VERSION=`echo $VERSION | sed 's/^\([[^\-]]*\).*/\1/'`
|
|
|
|
AC_SUBST(MAN_VERSION)
|
2009-06-02 17:36:58 +04:00
|
|
|
])
|