1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
|
From: Stefano Rivera <stefanor@debian.org>
Date: Sun, 17 Apr 2022 19:52:03 -0400
Subject: Use Debian package version
Upstream isn't making releases, and we can't trivially recreate the
upstream git describe output from our source package.
---
dist/version.sh | 21 ++-------------------
1 file changed, 2 insertions(+), 19 deletions(-)
diff --git a/dist/version.sh b/dist/version.sh
index e50000d..f97084a 100755
--- a/dist/version.sh
+++ b/dist/version.sh
@@ -1,21 +1,4 @@
#!/bin/sh
-MPV_PATH="`dirname $0`/../src/include/mp_version.h"
-
-MAJ=`awk '/MP_VERSION_MAJOR/ {print $3}' $MPV_PATH`
-MIN=`awk '/MP_VERSION_MINOR/ {print $3}' $MPV_PATH`
-PCH=`awk '/MP_VERSION_PATCH/ {print $3}' $MPV_PATH`
-
-# if git exists in path
-if type git >/dev/null 2>&1; then
- # and we are in a checkout
- if git rev-parse 2>/dev/null; then
- # but not on a tag (which means this is a release)
- if test -z "`git log 'HEAD^!' --format=%d 2>/dev/null | grep 'tag: '`"; then
- # append git revision hash to version
- GIT="-`git describe --always`"
- fi
- fi
-fi
-
-echo $MAJ.$MIN.$PCH$GIT
+cd $(dirname $0)/..
+dpkg-parsechangelog -S Version | cut -d - -f 1
|