初始提交
This commit is contained in:
54
dtest/ddr_test/Makefile
Normal file
54
dtest/ddr_test/Makefile
Normal file
@@ -0,0 +1,54 @@
|
||||
|
||||
# OUTPUT type
|
||||
# 1 - .out
|
||||
# 2 - .a
|
||||
# 3 - .so
|
||||
OUTPUT_TYPE = 1
|
||||
OUTPUT_NAME = ddr_test
|
||||
|
||||
SUB_DIRS = $(TOPDIR)/common/os_shim/dtestos
|
||||
|
||||
# .h files dir
|
||||
ADD_INCLUDE += $(TOPDIR)/inc/io_lib $(TOPDIR)/inc/driver $(TOPDIR)/driver/inc
|
||||
|
||||
# predefined macro
|
||||
PRE_MARCO +=
|
||||
|
||||
LD_SCRIPT = link_soc.lds
|
||||
#OPT_FLAG = -O0
|
||||
|
||||
ifeq ($(gcc),arm)
|
||||
ADD_LIB = cm3
|
||||
ADD_LIBDIR = $(TOPDIR)/startup/cm3
|
||||
else
|
||||
ADD_LIB = riscv
|
||||
ADD_LIBDIR =$(TOPDIR)/startup/riscv2
|
||||
endif
|
||||
|
||||
# lib dir
|
||||
ADD_LIBDIR += $(TOPDIR)/driver $(TOPDIR)/common/io_lib
|
||||
# lib need to ld together
|
||||
ADD_LIB += driver io_lib
|
||||
|
||||
#####################################################
|
||||
|
||||
ifdef TOPDIR
|
||||
include $(TOPDIR)/build/makefile.cfg
|
||||
else
|
||||
include $(CURDIR)/build/makefile.cfg
|
||||
TOPDIR = $(CURDIR)
|
||||
export TOPDIR
|
||||
endif
|
||||
|
||||
dump:
|
||||
$(OBJDUMP) -D -S -l $(OUTPUT_FULL_NAME) > $(OUTPUT_FULL_NAME).dump
|
||||
|
||||
# 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)
|
||||
Reference in New Issue
Block a user