diff options
author | Toni Uhlig <matzeton@googlemail.com> | 2022-05-16 13:02:34 +0200 |
---|---|---|
committer | Toni Uhlig <matzeton@googlemail.com> | 2022-05-16 13:22:45 +0200 |
commit | 128fb8e58c0d3e134afd8c413eae244366ef6235 (patch) | |
tree | 466f54b098ff6b4cc69ff8b5ae676b8cbd8ed73b | |
parent | 62fb26d86256972a270d3e265292f0d5fcc42585 (diff) |
Yet another approach to fix #1499 (basically a copy&pasta from @socketpair).do/some/maintenance
* Related to #1545, #1494 and #1189 as well
Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
-rw-r--r-- | configure.ac | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index c892e0cbf..8023a84a1 100644 --- a/configure.ac +++ b/configure.ac @@ -67,7 +67,7 @@ AC_DEFINE_UNQUOTED(NDPI_PATCH_LEVEL, "${NDPI_PATCH}", [nDPI patch level]) # .git as directory in a cloned repo # .git as file in submodule based integration -if test -d ".git" || test -f ".git" -a -d `cat .git | cut -d' ' -f2`; then : +if test -d ".git" || test -r ".git"; then GIT_TAG=`git log -1 --format=%h` GIT_DATE=`git log -1 --format=%cd` # @@ -87,11 +87,9 @@ else if test -z "$SOURCE_DATE_EPOCH" ; then : SOURCE_DATE_EPOCH=`date +%s` fi - NDPI_API_VERSION=`echo $SOURCE_DATE_EPOCH | cut -c7-10` + NDPI_API_VERSION=$((SOURCE_DATE_EPOCH % 65536)) fi -NDPI_API_VERSION=`echo $NDPI_API_VERSION | sed 's/^0*//'` - echo "Setting API version to $NDPI_API_VERSION" AC_DEFINE_UNQUOTED(NDPI_GIT_RELEASE, "${GIT_RELEASE}", [GIT Release]) |