-
Notifications
You must be signed in to change notification settings - Fork 4
/
makefile
32 lines (21 loc) · 1.01 KB
/
makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
APP_TOOLS_DIR := $(realpath $(dir $(lastword $(MAKEFILE_LIST))))
INIT_LOC = 0
LINKER_SCRIPT = $(APP_TOOLS_DIR)/linker_script
OUTPUT_MAP = NO
APP_SRC_FILE = $(APP_TOOLS_DIR)/app.src
DEPS := $(APP_SRC_FILE) $(APP_TOOLS_DIR)/makefile $(DEPS)
EXTRA_LDFLAGS += \
-i $(call QUOTE_ARG,provide __app_name = "$(APP_NAME)") \
-i $(call QUOTE_ARG,provide __app_version = "$(APP_VERSION)") \
-i $(call QUOTE_ARG,provide __app_desc = "$(DESCRIPTION)")
default: installer
include $(shell cedev-config --makefile)
TARGET8EK ?= $(NAME).8ek
APP_INST_NAME ?= APPINST
app: $(BINDIR)/$(TARGET8EK)
installer: $(BINDIR)/AppInstA.8xv
$(BINDIR)/$(TARGET8EK): $(BINDIR)/$(TARGETBIN) $(APP_TOOLS_DIR)/make_8ek.py
python3 $(APP_TOOLS_DIR)/make_8ek.py $(BINDIR)/$(TARGETBIN) $(BINDIR)/$(TARGET8EK) $(NAME)
$(BINDIR)/AppInstA.8xv: $(BINDIR)/$(TARGETBIN) $(APP_TOOLS_DIR)/installer.bin $(APP_TOOLS_DIR)/make_installer.py
python3 $(APP_TOOLS_DIR)/make_installer.py $(BINDIR)/$(TARGETBIN) $(BINDIR) $(NAME) $(APP_INST_NAME)
.PHONY: default installer app