Extract git commit from a package version

pull/3/head
Paolo Pantò 2019-09-06 15:28:07 +03:00 committed by Hleb Valoshka
parent 2b69c45efd
commit 1776830271
1 changed files with 9 additions and 1 deletions

10
debian/rules vendored
View File

@ -3,16 +3,24 @@
# Uncomment this to turn on verbose mode.
export DH_VERBOSE=1
include /usr/share/dpkg/pkg-info.mk
%:
dh $@
override_dh_auto_configure:
if echo "$(DEB_VERSION)" | grep -q '~git' ; then \
_git_commit=$$(echo "$(DEB_VERSION)" | cut -d'+' -f2) ; \
else \
_git_commit="unknown" ; \
fi ; \
dh_auto_configure --parallel -- \
-DENABLE_GLUT=ON \
-DENABLE_GTK=ON \
-DENABLE_QT=ON \
-DENABLE_TOOLS=ON \
-DCMAKE_BUILD_TYPE=RelWithDebInfo
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DGIT_COMMIT=\"$$_git_commit\"
override_dh_install: