Add SKIP_VERSION option to speed up compilation
This commit is contained in:
parent
e950d4e12f
commit
738b8d2b9c
18 changed files with 8 additions and 0 deletions
8
Makefile
8
Makefile
|
@ -534,14 +534,22 @@ test: test-all
|
||||||
.PHONY: test-clean
|
.PHONY: test-clean
|
||||||
test-clean: test-all-clean
|
test-clean: test-all-clean
|
||||||
|
|
||||||
|
ifdef SKIP_VERSION
|
||||||
|
SKIP_GIT := yes
|
||||||
|
endif
|
||||||
|
|
||||||
# Generate the version.h file
|
# Generate the version.h file
|
||||||
ifndef SKIP_GIT
|
ifndef SKIP_GIT
|
||||||
GIT_VERSION := $(shell git describe --abbrev=6 --dirty --always --tags 2>/dev/null || date +"%Y-%m-%d-%H:%M:%S")
|
GIT_VERSION := $(shell git describe --abbrev=6 --dirty --always --tags 2>/dev/null || date +"%Y-%m-%d-%H:%M:%S")
|
||||||
else
|
else
|
||||||
GIT_VERSION := NA
|
GIT_VERSION := NA
|
||||||
endif
|
endif
|
||||||
|
ifndef SKIP_VERSION
|
||||||
BUILD_DATE := $(shell date +"%Y-%m-%d-%H:%M:%S")
|
BUILD_DATE := $(shell date +"%Y-%m-%d-%H:%M:%S")
|
||||||
$(shell echo '#define QMK_VERSION "$(GIT_VERSION)"' > $(ROOT_DIR)/quantum/version.h)
|
$(shell echo '#define QMK_VERSION "$(GIT_VERSION)"' > $(ROOT_DIR)/quantum/version.h)
|
||||||
$(shell echo '#define QMK_BUILDDATE "$(BUILD_DATE)"' >> $(ROOT_DIR)/quantum/version.h)
|
$(shell echo '#define QMK_BUILDDATE "$(BUILD_DATE)"' >> $(ROOT_DIR)/quantum/version.h)
|
||||||
|
else
|
||||||
|
BUILD_DATE := NA
|
||||||
|
endif
|
||||||
|
|
||||||
include $(ROOT_DIR)/testlist.mk
|
include $(ROOT_DIR)/testlist.mk
|
||||||
|
|
Loading…
Reference in a new issue