summaryrefslogblamecommitdiff
path: root/version.make
blob: 7ceea8267245e3400f06d22afca2a175f331e8fa (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11

                                                                           








                                                                      

                                                                            


                   
VERSION_FULL := $(shell git --git-dir=${SRC_DIR}/.git describe --tags HEAD)
VERSION_HASH := $(shell git --git-dir=${SRC_DIR}/.git rev-parse HEAD)

version_bits := $(subst v, ,$(subst -, ,$(subst ., ,${VERSION_FULL})))
VERSION_MAJOR := $(word 1,${version_bits})
VERSION_MINOR := $(word 2,${version_bits})
VERSION_PATCH := $(word 3,${version_bits})
VERSION_DEVEL := $(word 4,${version_bits})
ifeq "${VERSION_DEVEL}" ""
    VERSION_DEVEL := 0
endif
# tracking dirty trees is more trouble than it's worth
#VERSION_FULL += $(shell cd ${SRC_DIR}; git diff --quiet HEAD || echo dirty)

VENDOR := Vanilla
VENDOR_VERSION := 0