diff --git a/Makefile b/Makefile index 4c01536..2961c7e 100644 --- a/Makefile +++ b/Makefile @@ -17,7 +17,7 @@ ifeq ("$(origin TAG)", "command line") TIMESTAMP := _p$(shell date +%Y%m%d) endif -VERSION := $(shell grep 'Version.*=' cli.c | sed 's/.*"\(.*\)";/\1/') +VERSION := $(shell grep 'Version.*=' espeakup.c | sed 's/.*"\(.*\)";/\1/') TAG := v$(VERSION) TARPREFIX := espeakup-$(VERSION) TARFILE := $(TARPREFIX)$(TIMESTAMP).tar diff --git a/cli.c b/cli.c index ecb9bb6..50d61f7 100644 --- a/cli.c +++ b/cli.c @@ -24,7 +24,7 @@ #include "espeakup.h" /* program version */ -const char *Version = "0.4"; +extern const char *Version; /* command line options */ const char *shortOptions = "dhv"; diff --git a/espeakup.c b/espeakup.c index e8da682..9f3c309 100644 --- a/espeakup.c +++ b/espeakup.c @@ -26,6 +26,9 @@ #include "espeakup.h" +/* program version */ +const char *Version = "0.4"; + /* path to our pid file */ const char *pidPath = "/var/run/espeakup.pid";