Commit adc663dd authored by Vivien Kraus's avatar Vivien Kraus

Fix libtool versionning

parent 747023dd
Pipeline #98770 failed with stages
in 2 minutes and 35 seconds
......@@ -3,13 +3,13 @@
AC_PREREQ([2.69])
AC_INIT([tarot],
m4_esyscmd([./git-version-gen .tarball-version]),
m4_esyscmd([./get-version.sh package]),
[vivien@planete-kraus.eu])
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIRS([m4 lib-library/m4 lib-program/m4])
AC_SUBST([LIBTOOL_CURRENT], m4_esyscmd([./git-version-gen .tarball-version | cut -d '.' -f 1]))
AC_SUBST([LIBTOOL_REVISION], m4_esyscmd([./git-version-gen .tarball-version | cut -d '.' -f 2]))
AC_SUBST([LIBTOOL_AGE], m4_esyscmd([./git-version-gen .tarball-version | cut -d '.' -f 3 | cut -d '-' -f 1]))
AC_SUBST([LIBTOOL_CURRENT], m4_esyscmd([./get-version.sh libtool | cut -d ':' -f 1]))
AC_SUBST([LIBTOOL_REVISION], m4_esyscmd([./get-version.sh libtool | cut -d ':' -f 2]))
AC_SUBST([LIBTOOL_AGE], m4_esyscmd([./get-version.sh libtool | cut -d ':' -f 3]))
# Checks for programs.
AC_PROG_CC
......
#!/bin/sh
PACKAGE_VERSION=$(./git-version-gen .tarball-version \
| sed 's|/[[:digit:]]\.[[:digit:]]\.[[:digit:]]||g')
LIBTOOL_VERSION=$(./git-version-gen .tarball-version \
| sed 's|.*/\([[:digit:]]\.[[:digit:]]\.[[:digit:]]\).*|\1|g' \
| sed 's/\./:/g')
case $1 in
package)
echo -n "$PACKAGE_VERSION";;
libtool)
echo -n "$LIBTOOL_VERSION";;
*)
echo -n "Usage: ./get-version.sh (package|libtool)" ; exit 1;;
esac
......@@ -17,7 +17,8 @@
# <http://www.gnu.org/licenses/>.
dist_noinst_SCRIPTS += \
git-version-gen
git-version-gen \
get-version.sh
EXTRA_DIST += $(top_srcdir)/.version
BUILT_SOURCES += $(top_srcdir)/.version
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment