Ingenic Jz4740: fix CPU boosting (was reversed)
[kugel-rb.git] / utils / wpseditor / libwps / Makefile
blobe74e26701b6c3cc2d227d15303c301f1b4814ce8
1 # __________ __ ___.
2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6 # \/ \/ \/ \/ \/
7 # $Id$
9 ROOT=../../..
11 ifneq ($or($(findstring MINGW,$(shell uname)),$(findstring Windows_NT,$(OS))),)
12 OS = w32
13 CC = mingw32-gcc
14 COPY = copy /Y
15 COPY_TO = ..\\gui\\bin
16 RM = del
17 EXT = .dll
18 LDFLAGS = -DBUILD_DLL
19 endif
21 ifeq ($(findstring Linux,$(shell uname)),Linux)
22 OS = linux
23 CC = gcc
24 COPY = cp -f
25 COPY_TO = ../gui/bin
26 RM = rm -f
27 EXT = .so
28 LDFLAGS = -fPIC
29 endif
31 TARGETS=IRIVER_H10 \
32 IRIVER_H10_5GB \
33 IPOD_COLOR \
34 IPOD_NANO \
35 IPOD_VIDEO \
36 IPOD_3G \
37 IPOD_4G \
38 IPOD_MINI \
39 IPOD_MINI2G \
40 IPOD_1G2G \
41 GIGABEAT_F \
42 GIGABEAT_S \
43 SANSA_E200 \
44 SANSA_C200 \
45 IRIVER_H100 \
46 IRIVER_H120 \
47 IRIVER_H300 \
48 IAUDIO_X5 \
49 IAUDIO_M5 \
50 IAUDIO_M3 \
52 SOURCES= \
53 src/api.c \
54 src/dummies.c \
55 src/lcd.c \
56 src/proxy.c \
57 $(ROOT)/apps/gui/scrollbar.c \
58 $(ROOT)/apps/gui/music_screen.c \
59 $(ROOT)/apps/gui/wps_engine/wps_display.c \
60 $(ROOT)/apps/gui/wps_engine/wps_tokens.c \
61 $(ROOT)/apps/gui/wps_engine/wps_parser.c \
62 $(ROOT)/apps/gui/wps_parser/wps_debug.c \
63 $(ROOT)/apps/recorder/peakmeter.c \
64 $(ROOT)/apps/recorder/icons.c \
65 $(ROOT)/apps/misc.c \
66 $(ROOT)/apps/status.c \
67 $(ROOT)/firmware/common/ctype.c \
68 $(ROOT)/firmware/common/timefuncs.c \
69 $(ROOT)/firmware/common/unicode.c \
70 $(ROOT)/firmware/font.c \
71 $(ROOT)/firmware/font_cache.c \
72 $(ROOT)/firmware/id3.c \
73 $(ROOT)/firmware/lru.c \
74 $(ROOT)/firmware/mp3data.c \
75 $(ROOT)/firmware/replaygain.c
76 # $(ROOT)/apps/recorder/bmp.c
77 # $(ROOT)/apps/abrepeat.c \
78 # $(ROOT)/apps/action.c \
79 # $(ROOT)/apps/cuesheet.c \
80 # $(ROOT)/apps/gui/statusbar.c \
81 # $(ROOT)/apps/gui/gwps.c \
83 INCLUDE=-I src/include \
84 -I $(ROOT)/apps/gui \
85 -I $(ROOT)/firmware/export \
86 -I $(ROOT)/firmware/include \
87 -I $(ROOT)/apps/recorder \
88 -I $(ROOT)/apps \
89 -I src
91 CFLAGS = -g -Wall -Wno-format -D__PCTOOL__ -DWPSEDITOR -DDEBUG -DROCKBOX_DIR_LEN=1 -DBUTTON_REMOTE
93 RESULTS := $(patsubst %,libwps_%$(EXT),$(TARGETS))
95 all: $(RESULTS)
97 libwps_%$(EXT): $(SOURCES)
98 @echo CC [$(subst libwps_,,$(subst $(EXT),,$@))]
99 @$(CC) $(INCLUDE) $(CFLAGS) -D$(subst libwps_,,$(subst $(EXT),,$@)) $(LDFLAGS) -shared -o $@ $+
100 @$(COPY) $@ $(COPY_TO)
102 clean:
103 $(RM) $(RESULTS)