forked from SDL-mirror/SDL
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile.wiiu
72 lines (64 loc) · 1.98 KB
/
Makefile.wiiu
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
BASEDIR := $(dir $(firstword $(MAKEFILE_LIST)))
VPATH := $(BASEDIR)
#---------------------------------------------------------------------------------
# Build options
#---------------------------------------------------------------------------------
TARGET = libSDL2.a
SOURCES = \
src/*.c \
src/atomic/*.c \
src/audio/*.c \
src/audio/wiiu/*.c \
src/cpuinfo/*.c \
src/events/*.c \
src/file/*.c \
src/haptic/*.c \
src/haptic/dummy/*.c \
src/joystick/*.c \
src/joystick/wiiu/*.c \
src/joystick/dummy/*.c \
src/loadso/dummy/*.c \
src/power/*.c \
src/filesystem/dummy/*.c \
src/render/*.c \
src/render/wiiu/*.c \
src/render/software/*.c \
src/stdlib/*.c \
src/sensor/*.c \
src/thread/*.c \
src/thread/wiiu/*.c \
src/timer/*.c \
src/timer/wiiu/*.c \
src/timer/dummy/*.c \
src/video/*.c \
src/video/wiiu/*.c \
src/video/yuv2rgb/*.c \
src/video/dummy/*.c
OBJECTS = $(shell echo $(SOURCES) | sed -e 's,\.c,\.o,g')
INCLUDE = -I./include
#---------------------------------------------------------------------------------
# Compile flags
#---------------------------------------------------------------------------------
CFLAGS += -O2 $(INCLUDE)
CXXFLAGS += -O2 $(INCLUDE)
#---------------------------------------------------------------------------------
# Build rules
#---------------------------------------------------------------------------------
.PHONY: clean install
$(TARGET): $(OBJECTS)
install: $(TARGET)
@echo INSTALL $(TARGET)
@mkdir -p $(PORTLIBS)/lib
@mkdir -p $(PORTLIBS)/include/SDL2
@cp $(TARGET) $(PORTLIBS)/lib/
@cp -f ./include/*.h $(PORTLIBS)/include/SDL2/
clean:
@echo CLEAN ...
@rm -rf $(OBJECTS) $(OBJECTS:.o=.d) $(TARGET)
#---------------------------------------------------------------------------------
# Toolchain
#---------------------------------------------------------------------------------
include $(WUT_ROOT)/share/wut.mk
LDFLAGS += -L$(DEVKITPRO)/portlibs/ppc/lib
CFLAGS += -I$(DEVKITPRO)/portlibs/ppc/include
CXXFLAGS += -I$(DEVKITPRO)/portlibs/ppc/include