mirror of
https://github.com/Zygo/bees.git
synced 2025-07-07 02:42:27 +02:00
Makefile: Specify version when building from tarball
When package maintainers build from a tarball, the .git directory does not exist to extract the version tag. Let's add a hack to work around this issue and let them specify `BEES_VERSION="v0.y"` on the make cmdline. Github-Bug: https://github.com/Zygo/bees/issues/75 Signed-off-by: Kai Krakow <kai@kaishome.de>
This commit is contained in:
@ -20,7 +20,7 @@ BEES_OBJS = \
|
||||
bees-types.o \
|
||||
|
||||
bees-version.c: bees.h $(BEES_OBJS:.o=.cc) Makefile
|
||||
echo "const char *BEES_VERSION = \"$(shell git describe --always --dirty || echo UNKNOWN)\";" > bees-version.new.c
|
||||
echo "const char *BEES_VERSION = \"$(BEES_VERSION)\";" > bees-version.new.c
|
||||
mv -f bees-version.new.c bees-version.c
|
||||
|
||||
.depends/%.dep: %.cc Makefile
|
||||
|
Reference in New Issue
Block a user