mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2024-12-23 21:34:35 +03:00
aa20a78b0e
* Add bootloader versioning * Move some logic to api-hal-version * Backport to f4 * Dolphin: update version screen layout, make it more readable Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
10 lines
572 B
Makefile
10 lines
572 B
Makefile
GIT_COMMIT = $(shell git describe --always --exclude '*' || echo 'unknown')
|
|
GIT_BRANCH = $(shell git rev-parse --abbrev-ref HEAD || echo 'unknown')
|
|
GIT_BRANCH_NUM = $(shell git rev-list --count $(GIT_BRANCH) || echo 'nan')
|
|
BUILD_DATE = $(shell date '+%d-%m-%Y' || echo 'unknown')
|
|
VERSION = $(shell git describe --tags --abbrev=0 || echo 'unknown')
|
|
|
|
CFLAGS += -DGIT_COMMIT="\"$(GIT_COMMIT)\"" -DGIT_BRANCH="\"$(GIT_BRANCH)\"" -DGIT_BRANCH_NUM="\"$(GIT_BRANCH_NUM)\""
|
|
CFLAGS += -DBUILD_DATE="\"$(BUILD_DATE)\"" -DTARGET="\"$(TARGET)\"" -DVERSION="\"$(VERSION)\""
|
|
|