📄 makefile
字号:
## @(#)Makefile# for GNU make## stop watch : sample program# Copyright (C) 2002-2004 by Personal Media Corporation## how to make# - make# make official version for release# - make mode=debug# create for debug# - make clean# delete all files created by make## source dependency file (automatically created)DEPS = DependenciesDEPENDENCIES_OUTPUT := $(DEPS)# standard ruleinclude ../../etc/makerules# ----------------------------------------------------------------------------# set USE_CONSOLE = 1 to use console input/output, set USE_CONDOLE = 0 to use LCD boardifneq ($(filter $(MACHINE), m32104 vr4131 lh79532), ) USE_CONSOLE = 1else USE_CONSOLE = 0endif# target to be createdTARGET = drawmap# search path for source filesS = ../srcVPATH = $S# source fileSRC = main.c navigator.c drawmap.c conv.c graphic.c map.c input.c gps.cifeq ($(USE_CONSOLE), 0) SRC += graphic.cendifOBJ = $(addsuffix .o, $(basename $(SRC)))# compile optionCFLAGS += $(CFLAGS_WARNING)ifeq ($(USE_CONSOLE), 1) CFLAGS += -DUSE_CONSOLEendif# ----------------------------------------------------------------------------.PHONY: all install cleanALL = $(TARGET) $(TARGET:%=%.map)ifeq ($(MACHINE), m32104) START_ADR = -Wl,-Ttext,0x04800000,-Tdata,0x04900000 ALL += $(TARGET:%=%.mot)endififeq ($(MACHINE), lh79532) START_ADR = -Wl,-Ttext,0x41000000,-Tdata,0x41010000 ALL += $(TARGET:%=%.mot)endififeq ($(MACHINE), nios2) START_ADR = -Wl,-Ttext,0x01800000,-Tdata,0x01900000 ALL += $(TARGET:%=%.mot)endifall: $(ALL)$(TARGET): $(OBJ) $(LINK.o) $(LDOBJS) $^ $(LOADLIBES) $(LDLIBS) $(OUTPUT_OPTION)$(TARGET:%=%.mot): $(TARGET) $(OBJCOPY) $(OUTPUT_SREC) $< $@clean: $(RM) $(OBJ) $(ALL) $(DEPS)install: $(addprefix $(EXE_INSTALLDIR)/, $(ALL))$(TARGET:%=$(EXE_INSTALLDIR)/%): $(EXE_INSTALLDIR)/%: % $(EXE_INSTALL_STRIP)# dependency of source filesifdef DEPENDENCIES_OUTPUT $(DEPS): ; touch $(DEPS)else $(DEPS): $(SRC) ; $(MAKEDEPS) $@ $?endifinclude $(DEPS)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -