Files
kunlun/os/freertos/Makefile

53 lines
1.2 KiB
Makefile
Raw Normal View History

2024-09-28 14:24:04 +08:00
# OUTPUT type
# 1 - .out
# 2 - .a
# 3 - .so
OUTPUT_TYPE = 2
OUTPUT_NAME = freertos
PRE_MARCO +=
ifeq ($(gcc), arm)
SUB_DIRS = src src/portable/ARM_CM3 src/portable/MemMang
ADD_INCLUDE += src/include src/portable/ARM_CM3
else
SUB_DIRS = src src/portable/RISCV
ifeq ($(target), kunlun2)
ifeq ($(product_line), PLC)
SUB_DIRS += src/portable/MemMang/heap_5
else
SUB_DIRS += src/portable/MemMang/heap_4
endif
else
ifeq ($(target), kunlun3)
SUB_DIRS += src/portable/MemMang/heap_5
else
SUB_DIRS += src/portable/MemMang/heap_5
endif
endif
ADD_INCLUDE += src/include src/portable/RISCV $(TOPDIR)/startup/riscv/inc
endif
# lib dir
ADD_LIBDIR =
# lib need to ld together
ADD_LIB =
ifdef TOPDIR
include $(TOPDIR)/build/makefile.cfg
else
include $(CURDIR)/build/makefile.cfg
TOPDIR = $(CURDIR)
export TOPDIR
endif
# display the obj files and output name
debug:
@echo TOPDIR=$(TOPDIR)
@echo OUTPUT_LIB=$(OUTPUT_FULL_NAME)
@echo DEPS=$(DEPS)
@echo OBJECTS=$(OBJECTS)
@echo SRCS=$(SRCS)
@echo OBJECTS folder=$(foreach dirname, $(SUB_DIRS), $(addprefix $(BIN_DIR)/, $(dirname)))
@echo output_name=$(OUTPUT_FULL_NAME)