⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 makefile

📁 LPC based lcd interface
💻
字号:

#include the generic definitions for the EB01 examples
include ../make.defs

#define the directoriues for the object code for the multile targets
IRQBLOCK=IRQBLOCK_OBJ
IRQCHAR=IRQCHAR_OBJ
POLLING=POLLING_OBJ


#make all the different targets
all:
	make angel
	make ice
	make release

#make all the angel debug targets
.PHONY : angel
angel :
	make irqblock_angel
	make irqchar_angel
	make polling_angel

#make all the ICE debug targets
.PHONY : ice
ice :
	make irqblock_ice
	make irqchar_ice
	make polling_ice

#make all the release targets
.PHONY : release
release :
	make irqblock_release
	make irqchar_release
	make polling_release
	
#these are the rules for all the targets

.PHONY : irqblock_angel
irqblock_angel:
	if [ -d $(IRQBLOCK) ]; then true; else mkdir $(IRQBLOCK);fi
	if [ -d $(IRQBLOCK)/$(ANGEL) ]; then true; else mkdir $(IRQBLOCK)/$(ANGEL);fi
	make $(IRQBLOCK)/$(ANGEL)/irqblock.bin OBJ=$(IRQBLOCK)/$(ANGEL)/ DEBUG="AT91_DEBUG_ANGEL=1"
	
.PHONY : irqblock_ice
irqblock_ice:
	if [ -d $(IRQBLOCK) ]; then true; else mkdir $(IRQBLOCK);fi
	if [ -d $(IRQBLOCK)/$(ICE) ]; then true; else mkdir $(IRQBLOCK)/$(ICE);fi
	make $(IRQBLOCK)/$(ICE)/irqblock.bin OBJ=$(IRQBLOCK)/$(ICE)/ DEBUG="AT91_DEBUG_ICE=1"
	
.PHONY : irqblock_release
irqblock_release:
	if [ -d $(IRQBLOCK) ]; then true; else mkdir $(IRQBLOCK);fi
	if [ -d $(IRQBLOCK)/$(RELEASE) ]; then true; else mkdir $(IRQBLOCK)/$(RELEASE);fi
	make $(IRQBLOCK)/$(RELEASE)/irqblock.bin OBJ=$(IRQBLOCK)/$(RELEASE)/ DEBUG="AT91_DEBUG_NONE=1"

.PHONY : irqchar_angel
irqchar_angel:
	if [ -d $(IRQCHAR) ]; then true; else mkdir $(IRQCHAR);fi
	if [ -d $(IRQCHAR)/$(ANGEL) ]; then true; else mkdir $(IRQCHAR)/$(ANGEL);fi
	make $(IRQCHAR)/$(ANGEL)/irqchar.bin OBJ=$(IRQCHAR)/$(ANGEL)/ DEBUG="AT91_DEBUG_ANGEL=1"
	
.PHONY : irqchar_ice
irqchar_ice:
	if [ -d $(IRQCHAR) ]; then true; else mkdir $(IRQCHAR);fi
	if [ -d $(IRQCHAR)/$(ICE) ]; then true; else mkdir $(IRQCHAR)/$(ICE);fi
	make $(IRQCHAR)/$(ICE)/irqchar.bin OBJ=$(IRQCHAR)/$(ICE)/ DEBUG="AT91_DEBUG_ICE=1"
	
.PHONY : irqchar_release
irqchar_release:
	if [ -d $(IRQCHAR) ]; then true; else mkdir $(IRQCHAR);fi
	if [ -d $(IRQCHAR)/$(RELEASE) ]; then true; else mkdir $(IRQCHAR)/$(RELEASE);fi
	make $(IRQCHAR)/$(RELEASE)/irqchar.bin OBJ=$(IRQCHAR)/$(RELEASE)/ DEBUG="AT91_DEBUG_NONE=1"

.PHONY : polling_angel
polling_angel:
	if [ -d $(POLLING) ]; then true; else mkdir $(POLLING);fi
	if [ -d $(POLLING)/$(ANGEL) ]; then true; else mkdir $(POLLING)/$(ANGEL);fi
	make $(POLLING)/$(ANGEL)/polling.bin OBJ=$(POLLING)/$(ANGEL)/ DEBUG="AT91_DEBUG_ANGEL=1"
	
.PHONY : polling_ice
polling_ice:
	if [ -d $(POLLING) ]; then true; else mkdir $(POLLING);fi
	if [ -d $(POLLING)/$(ICE) ]; then true; else mkdir $(POLLING)/$(ICE);fi
	make $(POLLING)/$(ICE)/polling.bin OBJ=$(POLLING)/$(ICE)/ DEBUG="AT91_DEBUG_ICE=1"
	
.PHONY : polling_release
polling_release:
	if [ -d $(POLLING) ]; then true; else mkdir $(POLLING);fi
	if [ -d $(POLLING)/$(RELEASE) ]; then true; else mkdir $(POLLING)/$(RELEASE);fi
	make $(POLLING)/$(RELEASE)/polling.bin OBJ=$(POLLING)/$(RELEASE)/ DEBUG="AT91_DEBUG_NONE=1"


IRQBLOCK_OBJS = $(OBJ)in_main.o $(OBJ)irqblock.o $(OBJ)asm_path.o32 $(OBJ)in_eb01.o32 $(OBJ)in_reset.o32

$(OBJ)irqblock.bin : $(IRQBLOCK_OBJS)
	$(LINK) $(LDFLAGS) -o $(OBJ)irqblock.bin $(IRQBLOCK_OBJS) $(ANGEL_LIB) $(AT91_LIB32) $(LIBC) $(GCC_LIB)

IRQCHAR_OBJS = $(OBJ)in_main.o $(OBJ)irqchar.o $(OBJ)asm_path.o32 $(OBJ)in_eb01.o32 $(OBJ)in_reset.o32

$(OBJ)irqchar.bin : $(IRQCHAR_OBJS)
	$(LINK) $(LDFLAGS) -o $(OBJ)irqchar.bin $(IRQCHAR_OBJS) $(ANGEL_LIB) $(AT91_LIB32) $(LIBC) $(GCC_LIB)

POLLING_OBJS = $(OBJ)in_main.o $(OBJ)polling.o $(OBJ)asm_path.o32 $(OBJ)in_eb01.o32 $(OBJ)in_reset.o32

$(OBJ)polling.bin : $(POLLING_OBJS)
	$(LINK) $(LDFLAGS) -o $(OBJ)polling.bin $(POLLING_OBJS) $(ANGEL_LIB) $(AT91_LIB32) $(LIBC) $(GCC_LIB)

$(OBJ)irqblock.o : irqblock.c $(INCLUDE)/eb01.h $(INCLUDE)/std_c.h $(INCLUDE)/usart.h $(AT91_LIB)/lib_usart.c

$(OBJ)irqchar.o : irqchar.c $(INCLUDE)/eb01.h $(INCLUDE)/std_c.h $(INCLUDE)/usart.h $(AT91_LIB)/lib_usart.c

$(OBJ)polling.o : polling.c

$(OBJ)in_main.o : $(INIT_LIB)/in_main.c $(INCLUDE)/ebi.h $(INCLUDE)/std_c.h

$(OBJ)asm_path.o32 : ../../asm_path.s

$(OBJ)in_eb01.o32 : $(INIT_LIB)/in_eb01.s $(INCLUDE)/ebi.inc

$(OBJ)in_reset.o32 : $(INIT_LIB)/in_reset.s $(INCLUDE)/aic.inc $(INCLUDE)/arm.inc $(INCLUDE)/int_mem.inc

clean:
	 $(RM) $(IRQBLOCK)/$(ANGEL)/*.o* $(IRQBLOCK)/$(ANGEL)/*.bin
	 $(RM) $(IRQBLOCK)/$(ICE)/*.o* $(IRQBLOCK)/$(ICE)/*.bin
	 $(RM) $(IRQBLOCK)/$(RELEASE)/*.o* $(IRQBLOCK)/$(RELEASE)/*.bin
	 $(RM) $(IRQCHAR)/$(ANGEL)/*.o* $(IRQCHAR)/$(ANGEL)/*.bin
	 $(RM) $(IRQCHAR)/$(ICE)/*.o* $(IRQCHAR)/$(ICE)/*.bin
	 $(RM) $(IRQCHAR)/$(RELEASE)/*.o* $(IRQCHAR)/$(RELEASE)/*.bin
	 $(RM) $(POLLING)/$(ANGEL)/*.o* $(POLLING)/$(ANGEL)/*.bin
	 $(RM) $(POLLING)/$(ICE)/*.o* $(POLLING)/$(ICE)/*.bin
	 $(RM) $(POLLING)/$(RELEASE)/*.o* $(POLLING)/$(RELEASE)/*.bin
	 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -