Add a png viewer plugin
[kugel-rb.git] / apps / plugins / png / png.make
blob8f4ef39e72d585af300510a25a3c093cbba821f3
1 # __________ __ ___.
2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6 # \/ \/ \/ \/ \/
7 # $Id$
10 PNGSRCDIR := $(APPSDIR)/plugins/png
11 PNGBUILDDIR := $(BUILDDIR)/apps/plugins/png
13 ROCKS += $(PNGBUILDDIR)/png.rock
15 PNG_SRC := $(call preprocess, $(PNGSRCDIR)/SOURCES)
16 PNG_OBJ := $(call c2obj, $(PNG_SRC))
18 # add source files to OTHER_SRC to get automatic dependencies
19 OTHER_SRC += $(PNG_SRC)
21 # Use -O3 for png plugin : it gives a bigger file but very good performances
22 PNGFLAGS = $(PLUGINFLAGS) -O3 -DNO_GZCOMPRESS -DNO_GZIP
24 $(PNGBUILDDIR)/png.rock: $(PNG_OBJ)
26 # Compile PNG plugin with extra flags (adapted from ZXBox)
27 $(PNGBUILDDIR)/%.o: $(PNGSRCDIR)/%.c $(PNGSRCDIR)/png.make
28 $(SILENT)mkdir -p $(dir $@)
29 $(call PRINTS,CC $(subst $(ROOTDIR)/,,$<))$(CC) -I$(dir $<) $(PNGFLAGS) -c $< -o $@