forked from ntrteam/ntrboot_flasher
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
34 lines (24 loc) · 823 Bytes
/
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
33
34
rwildcard = $(foreach d, $(wildcard $1*), $(filter $(subst *, %, $2), $d) $(call rwildcard, $d/, $2))
ifeq ($(strip $(DEVKITARM)),)
$(error "Please set DEVKITARM in your environment. export DEVKITARM=<path to>devkitARM")
endif
include $(DEVKITARM)/base_tools
name := ntrboot_flasher
dir_libelm := libelm
dir_ntrboot_flasher := ntrboot_flasher
.PHONY: $(dir_libelm)
.PHONY: $(dir_ntrboot_flasher)
.PHONY: all
.PHONY: firm
all: ntrboot_flasher.firm
ntrboot_flasher.firm: $(dir_ntrboot_flasher)/ntrboot_flasher.firm
@cp $< $(@D)
$(dir_libelm)/libelm.a: $(dir_libelm)
@$(MAKE) -C $<
$(dir_ntrboot_flasher)/ntrboot_flasher.firm: $(dir_ntrboot_flasher) $(dir_libelm)/libelm.a
@$(MAKE) -C $<
.PHONY: clean
clean:
@$(MAKE) -C $(dir_libelm) clean
@$(MAKE) -C $(dir_ntrboot_flasher) clean
rm -rf ntrboot_flasher.firm