Skip to content

Commit 94e1345

Browse files
committed
build: embed the git commit id of HEAD in the configure script
Acked-by: Thomas Graf <[email protected]> Signed-off-by: Thomas Haller <[email protected]>
1 parent c62cda9 commit 94e1345

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

configure.ac

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
m4_define([libnl_major_version], [3])
1515
m4_define([libnl_minor_version], [2])
1616
m4_define([libnl_micro_version], [25])
17+
m4_define([libnl_git_sha], [m4_esyscmd([ ( [ -d ./.git/ ] && [ "$(readlink -f ./.git/)" = "$(readlink -f "$(git rev-parse --git-dir 2>/dev/null)" 2>/dev/null)" ] && git rev-parse --verify -q HEAD 2>/dev/null ) || true ])])
1718

1819

1920
# The following explanation may help to understand the above rules a bit
@@ -55,6 +56,7 @@ MIN_VERSION=libnl_minor_version
5556
AC_SUBST(MIN_VERSION)
5657
MIC_VERSION=libnl_micro_version
5758
AC_SUBST(MIC_VERSION)
59+
LIBNL_GIT_SHA=libnl_git_sha
5860
LIBNL_VERSION=libnl_version
5961
AC_SUBST(LIBNL_VERSION)
6062

0 commit comments

Comments
 (0)