summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorUlrich Eckhardt <uli@uli-eckhardt.de>2018-02-27 18:57:47 +0100
committerUlrich Eckhardt <uli@uli-eckhardt.de>2018-02-27 18:57:47 +0100
commite5c487fd9ec36053525c98d4a9674717042bb34c (patch)
treefd7a97d126056023fb92a7f8f04cf132b3e62b21 /Makefile
parentb6287a384f7cc0e6be140e5fa069dc53c02eb98e (diff)
downloadvdr-plugin-menuorg-e5c487fd9ec36053525c98d4a9674717042bb34c.tar.gz
vdr-plugin-menuorg-e5c487fd9ec36053525c98d4a9674717042bb34c.tar.bz2
Add git version information
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile10
1 files changed, 7 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 4b8b901..f822c3a 100644
--- a/Makefile
+++ b/Makefile
@@ -4,9 +4,12 @@
PLUGIN = menuorg
-### The version number of this plugin (taken from the main source file):
+### The version number of this plugin (taken from Version.h):
-VERSION = $(shell grep 'static const char VERSION\[\] =' src/Version.h | awk '{ print $$6 }' | sed -e 's/[";]//g')
+VERSION = $(shell grep 'static const char VERSION\[\] =' src/Version.h | \
+ grep -v GIT | awk '{ print $$6 }' | sed -e 's/[";]//g')
+
+GIT_REV = $(shell git describe --always 2>/dev/null)
### The directory environment:
@@ -48,7 +51,8 @@ INCLUDES += `pkg-config glibmm-2.4 --cflags`
LIBS += `pkg-config libxml++-2.6 --libs`
LIBS += `pkg-config glibmm-2.4 --libs`
-DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"'
+DEFINES += -DPLUGIN_NAME_I18N='"$(PLUGIN)"' \
+ $(if $(GIT_REV), -DGIT_REV='"$(GIT_REV)"')
### The source files (add further files here):