2008-11-20 11:27:31 +00:00
|
|
|
# __________ __ ___.
|
|
|
|
# Open \______ \ ____ ____ | | _\_ |__ _______ ___
|
|
|
|
# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
|
|
|
|
# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
|
|
|
|
# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
|
|
|
|
# \/ \/ \/ \/ \/
|
2008-11-25 19:54:23 +00:00
|
|
|
# $Id$
|
2008-11-20 11:27:31 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
MPEGSRCDIR := $(APPSDIR)/plugins/mpegplayer
|
|
|
|
MPEGBUILDDIR := $(BUILDDIR)/apps/plugins/mpegplayer
|
|
|
|
|
|
|
|
ROCKS += $(MPEGBUILDDIR)/mpegplayer.rock
|
|
|
|
|
|
|
|
MPEG_SRC := $(call preprocess, $(MPEGSRCDIR)/SOURCES)
|
|
|
|
MPEG_OBJ := $(call c2obj, $(MPEG_SRC))
|
|
|
|
|
|
|
|
# add source files to OTHER_SRC to get automatic dependencies
|
|
|
|
OTHER_SRC += $(MPEG_SRC)
|
|
|
|
|
2011-09-08 06:23:33 +00:00
|
|
|
# Set '-fgnu89-inline' if supported (GCCVER >= 4.1.3, GCCNUM > 401)
|
|
|
|
ifeq ($(shell expr $(GCCNUM) \> 401),1)
|
2011-09-03 18:46:44 +00:00
|
|
|
MPEGCFLAGS = $(PLUGINFLAGS) -fgnu89-inline
|
|
|
|
else
|
|
|
|
MPEGCFLAGS = $(PLUGINFLAGS)
|
|
|
|
endif
|
2011-09-03 18:27:14 +00:00
|
|
|
|
2008-11-20 11:27:31 +00:00
|
|
|
$(MPEGBUILDDIR)/mpegplayer.rock: $(MPEG_OBJ) $(CODECDIR)/libmad-mpeg.a
|
2011-09-03 18:27:14 +00:00
|
|
|
|
|
|
|
$(MPEGBUILDDIR)/%.o: $(MPEGSRCDIR)/%.c $(MPEGSRCDIR)/mpegplayer.make
|
|
|
|
$(SILENT)mkdir -p $(dir $@)
|
|
|
|
$(call PRINTS,CC $(subst $(ROOTDIR)/,,$<))$(CC) -I$(dir $<) $(MPEGCFLAGS) -c $< -o $@
|