2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 TOOLSCFLAGS
:= -O
-g
-W
-Wall
-Wshadow
-pedantic
-I
$(ROOTDIR
)/tools
12 $(TOOLSDIR
)/scramble
: $(TOOLSDIR
)/scramble.c
$(TOOLSDIR
)/iriver.c \
13 $(TOOLSDIR
)/mi4.c
$(TOOLSDIR
)/gigabeat.c \
14 $(TOOLSDIR
)/gigabeats.c
$(TOOLSDIR
)/telechips.c \
15 $(TOOLSDIR
)/iaudio_bl_flash.c \
16 $(TOOLSDIR
)/creative.c
$(TOOLSDIR
)/hmac-sha1.c \
19 $(TOOLSDIR
)/rdf2binary
: $(TOOLSDIR
)/rdf2binary.c
20 $(TOOLSDIR
)/convbdf
: $(TOOLSDIR
)/convbdf.c
21 $(TOOLSDIR
)/codepages
: $(TOOLSDIR
)/codepages.c
$(TOOLSDIR
)/codepage_tables.c
22 $(TOOLSDIR
)/mkboot
: $(TOOLSDIR
)/mkboot.c
23 $(TOOLSDIR
)/wavtrim
: $(TOOLSDIR
)/wavtrim.c
24 $(TOOLSDIR
)/voicefont
: $(TOOLSDIR
)/voicefont.c
26 $(TOOLSDIR
)/iaudio_bl_flash.c
$(TOOLSDIR
)/iaudio_bl_flash.h
: $(TOOLSDIR
)/iaudio_bl_flash.bmp
$(TOOLSDIR
)/bmp2rb
27 $(call PRINTS
,BMP2RB
$(@F
))
28 $(SILENT
)$(TOOLSDIR
)/bmp2rb
-f
7 -h
$(TOOLSDIR
) $< >$(TOOLSDIR
)/iaudio_bl_flash.c
30 $(TOOLSDIR
)/bmp2rb
: $(TOOLSDIR
)/bmp2rb.c
31 $(call PRINTS
,CC
$(@F
))
32 $(SILENT
)$(HOSTCC
) -DAPPLICATION_NAME
=\"$@
\" $(TOOLSCFLAGS
) $+ -o
$@
34 $(TOOLSDIR
)/uclpack
: $(TOOLSDIR
)/ucl
/uclpack.c
$(wildcard $(TOOLSDIR
)/ucl
/src
/*.c
)
35 $(call PRINTS
,CC
$(@F
))$(HOSTCC
) $(TOOLSCFLAGS
) -I
$(TOOLSDIR
)/ucl \
36 -I
$(TOOLSDIR
)/ucl
/include -o
$@
$^
38 $(TOOLSDIR
)/convttf
: $(TOOLSDIR
)/convttf.c
39 $(call PRINTS
,CC
$(@F
))
40 $(SILENT
)$(HOSTCC
) $(TOOLSFLAGS
) -lm
-O2
-Wall
-g
$+ -o
$@ \
41 `freetype-config --libs` `freetype-config --cflags`
43 $(TOOLSDIR
)/player_unifont
: $(TOOLSDIR
)/player_unifont.c
$(ROOTDIR
)/firmware
/drivers
/lcd-charset-player.c
44 $(call PRINTS
,CC
$(@F
))
45 $(SILENT
)$(HOSTCC
) $(TOOLSFLAGS
) -DARCHOS_PLAYER
-D__PCTOOL__
-I
$(ROOTDIR
)/firmware
/export -I.
$+ -o
$@
47 # implicit rule for simple tools
48 $(TOOLSDIR
)/%: $(TOOLSDIR
)/%.c
49 $(call PRINTS
,CC
$(subst $(ROOTDIR
)/,,$@
))
50 $(SILENT
)$(HOSTCC
) $(TOOLSCFLAGS
) -o
$@
$^