correct MK_BOOTLOADER_VERSION to same as git tag version
This commit is contained in:
parent
5eac387b5a
commit
01f854c3db
26
Makefile
26
Makefile
@ -1,11 +1,11 @@
|
|||||||
#******************************************************************************
|
#******************************************************************************
|
||||||
# CONFIGURE
|
# CONFIGURE
|
||||||
# - SDK_PATH : path to SDK directory
|
# - SDK_PATH : path to SDK directory
|
||||||
# - SRC_PATH : path to src folder
|
# - SRC_PATH : path to src folder
|
||||||
#
|
#
|
||||||
# - SD_NAME : e.g s132, s140
|
# - SD_NAME : e.g s132, s140
|
||||||
# - SD_VER1, SD_VER2, SD_VER3: SoftDevice version e.g 6.0.0
|
# - SD_VERSSION : SoftDevice version e.g 6.0.0
|
||||||
# - SD_HEX : to bootloader hex binary
|
# - SD_HEX : to bootloader hex binary
|
||||||
#******************************************************************************
|
#******************************************************************************
|
||||||
SRC_PATH = src
|
SRC_PATH = src
|
||||||
|
|
||||||
@ -16,16 +16,12 @@ SD_PATH = lib/softdevice/$(SD_FILENAME)
|
|||||||
TUSB_PATH = lib/tinyusb/src
|
TUSB_PATH = lib/tinyusb/src
|
||||||
NRFX_PATH = lib/nrfx
|
NRFX_PATH = lib/nrfx
|
||||||
|
|
||||||
SD_VER1 = 6
|
SD_VERSION = 6.1.1
|
||||||
SD_VER2 = 1
|
|
||||||
SD_VER3 = 1
|
|
||||||
|
|
||||||
SD_VERSION = $(SD_VER1).$(SD_VER2).$(SD_VER3)
|
|
||||||
SD_FILENAME = $(SD_NAME)_nrf52_$(SD_VERSION)
|
SD_FILENAME = $(SD_NAME)_nrf52_$(SD_VERSION)
|
||||||
SD_API_PATH = $(SD_PATH)/$(SD_FILENAME)_API
|
SD_API_PATH = $(SD_PATH)/$(SD_FILENAME)_API
|
||||||
SD_HEX = $(SD_PATH)/$(SD_FILENAME)_softdevice.hex
|
SD_HEX = $(SD_PATH)/$(SD_FILENAME)_softdevice.hex
|
||||||
|
|
||||||
LD_FILE = $(SRC_PATH)/linker/$(SD_NAME)_v$(SD_VER1).ld
|
LD_FILE = $(SRC_PATH)/linker/$(SD_NAME)_v$(word 1, $(subst ., ,$(SD_VERSION))).ld
|
||||||
|
|
||||||
MERGED_FNAME = $(OUTPUT_FILENAME)_$(SD_NAME)_$(SD_VERSION)
|
MERGED_FNAME = $(OUTPUT_FILENAME)_$(SD_NAME)_$(SD_VERSION)
|
||||||
|
|
||||||
@ -33,6 +29,7 @@ GIT_VERSION = $(shell git describe --dirty --always --tags)
|
|||||||
GIT_SUBMODULE_VERSIONS = $(shell git submodule status | cut -d' ' -f3,4 | paste -s -d" " -)
|
GIT_SUBMODULE_VERSIONS = $(shell git submodule status | cut -d' ' -f3,4 | paste -s -d" " -)
|
||||||
|
|
||||||
OUTPUT_FILENAME = $(BOARD)_bootloader-$(GIT_VERSION)
|
OUTPUT_FILENAME = $(BOARD)_bootloader-$(GIT_VERSION)
|
||||||
|
|
||||||
#******************************************************************************
|
#******************************************************************************
|
||||||
# Tool configure
|
# Tool configure
|
||||||
#******************************************************************************
|
#******************************************************************************
|
||||||
@ -240,10 +237,6 @@ CFLAGS += -ffunction-sections -fdata-sections -fno-strict-aliasing
|
|||||||
CFLAGS += -fno-builtin --short-enums -fstack-usage
|
CFLAGS += -fno-builtin --short-enums -fstack-usage
|
||||||
|
|
||||||
# Defined Symbol (MACROS)
|
# Defined Symbol (MACROS)
|
||||||
|
|
||||||
# TODO use GIT_VERSION (numberic format)
|
|
||||||
CFLAGS += -DMK_BOOTLOADER_VERSION=0x0$(SD_VER1)0$(SD_VER2)0$(SD_VER3)UL
|
|
||||||
|
|
||||||
CFLAGS += -D__HEAP_SIZE=0
|
CFLAGS += -D__HEAP_SIZE=0
|
||||||
CFLAGS += -DCONFIG_GPIO_AS_PINRESET
|
CFLAGS += -DCONFIG_GPIO_AS_PINRESET
|
||||||
CFLAGS += -DCONFIG_NFCT_PINS_AS_GPIOS
|
CFLAGS += -DCONFIG_NFCT_PINS_AS_GPIOS
|
||||||
@ -256,6 +249,9 @@ CFLAGS += -DDFU_APP_DATA_RESERVED=7*4096
|
|||||||
CFLAGS += -DUF2_VERSION='"$(GIT_VERSION) $(GIT_SUBMODULE_VERSIONS) $(SD_NAME) $(SD_VERSION)"'
|
CFLAGS += -DUF2_VERSION='"$(GIT_VERSION) $(GIT_SUBMODULE_VERSIONS) $(SD_NAME) $(SD_VERSION)"'
|
||||||
CFLAGS += -DBLEDIS_FW_VERSION='"$(GIT_VERSION) $(SD_NAME) $(SD_VERSION)"'
|
CFLAGS += -DBLEDIS_FW_VERSION='"$(GIT_VERSION) $(SD_NAME) $(SD_VERSION)"'
|
||||||
|
|
||||||
|
_VER = $(subst ., ,$(word 1, $(subst -, ,$(GIT_VERSION))))
|
||||||
|
CFLAGS += -DMK_BOOTLOADER_VERSION='($(word 1,$(_VER)) << 16) + ($(word 2,$(_VER)) << 8) + $(word 3,$(_VER))'
|
||||||
|
|
||||||
ifneq ($(IS_52832),)
|
ifneq ($(IS_52832),)
|
||||||
CFLAGS += -DNRF52
|
CFLAGS += -DNRF52
|
||||||
CFLAGS += -DNRF52832_XXAA
|
CFLAGS += -DNRF52832_XXAA
|
||||||
|
Loading…
Reference in New Issue
Block a user