From 9e946aeefb3c54dac287cf663f78398d7e18e739 Mon Sep 17 00:00:00 2001 From: tkl Date: Fri, 29 Jul 2016 08:51:56 +0200 Subject: [PATCH] os lib naming unified --- config/make/rules.mk | 9 +++++---- config/make/stm32f4xx.mk | 5 ++++- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/config/make/rules.mk b/config/make/rules.mk index 77091f0..d0d3dc7 100755 --- a/config/make/rules.mk +++ b/config/make/rules.mk @@ -11,7 +11,9 @@ endif INCLUDES += $(SRC_DIR)/os/$(DBG_REL_DIR)/include LIB_DIR += $(SRC_DIR)/os/$(DBG_REL_DIR) -LIBS += kosmos-arm-stm32f4-discovery-dbg + +OS_LIB = kosmos-$(ARCH)-$(BOARD)$(DBG_EXT) +LIBS += $(OS_LIB) CFLAGS += \ -O$(OPTIM) \ @@ -28,11 +30,9 @@ CPPCHECK_FLAGS += \ include $(ROOT_DIR)/config/make/tools.mk SRC_DIR = $(ROOT_DIR)/source - +DBG_REL_DIR = release ifeq ($(DEBUG),y) DBG_REL_DIR = debug -else -DBG_REL_DIR = release endif OBJ_DIR = $(ROOT_DIR)/release/object/$(ARCH)/$(DBG_REL_DIR) @@ -48,6 +48,7 @@ DOC_SRC := ELF_EXT = .elf BIN_EXT = .bin HEX_EXT = .hex +LIB_EXT = .a SIZE_EXT = .size TEST_EXT = diff --git a/config/make/stm32f4xx.mk b/config/make/stm32f4xx.mk index ad30c83..39113d7 100644 --- a/config/make/stm32f4xx.mk +++ b/config/make/stm32f4xx.mk @@ -1,4 +1,5 @@ -ARCH ?= stm32f4xx +ARCH ?= arm +CPU ?= stm32f4xx ifeq ($(ARCH),stm32f4xx) CFLAGS += -DARCH_STM32F4XX endif @@ -14,9 +15,11 @@ INCLUDES += \ ifeq ($(DEBUG),y) OPTIM = 0 CFLAGS += -g +DBG_EXT = -dbg else OPTIM = s LDFLAGS += -s +DBG_EXT = endif CFLAGS += \