-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
43 lines (34 loc) · 890 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
35
36
37
38
39
40
41
42
43
#==============================================================================
# ■ makefile
#==============================================================================
include inc.makefile
PROJECTS = lib/lodepng lib/ASM76 VMDE VMGS
PROJECT_ROOT = $(shell pwd)
all: $(PROJECTS)
$(PROJECTS):
cd $@ && $(MAKE) -f build/$(PLATFORM).makefile MAKE76_ROOT=$(PROJECT_ROOT)
clean:
ifeq "$(PLATFORM)" "msw"
del /s *.o *.o-????????
del VMGS\output.log
else
find . -name "*.o" -print -delete
$(RM) VMGS/output.log
endif
run:
$(MAKE) $(PROJECTS) MODE=test
ifeq "$(PLATFORM)" "msw"
call windows_path.bat && cd VMGS && VMGS.exe
else
cd VMGS && ./VMGS
endif
debug:
$(MAKE) $(PROJECTS) MODE=debug
ifeq "$(PLATFORM)" "msw"
call windows_path.bat && cd VMGS && gdb VMGS.exe
else
cd VMGS && gdb VMGS
endif
platform:
@echo $(PLATFORM)
.PHONY: all clean run debug $(PROJECTS) platform