rockbox/tools/rbspeex/Makefile
Thom Johansen 65458ee71c Speex encoder specially tailored to create voice UI snippets. Small fixups to libspeex to allow it to be built.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15640 a1c6a512-1295-4272-9138-f99709370657
2007-11-16 15:35:37 +00:00

56 lines
1.5 KiB
Makefile

# __________ __ ___.
# Open \______ \ ____ ____ | | _\_ |__ _______ ___
# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
# \/ \/ \/ \/ \/
# $Id: Makefile,v 1.16 2006-09-02 22:34:13 bagder Exp $
#
ifndef V
SILENT = @
endif
SPEEXSRC = ../../apps/codecs/libspeex
INCLUDES = -I $(SPEEXSRC) -iquote $(SPEEXSRC)
SPEEXOPTS = -DHAVE_CONFIG_H -DROCKBOX_VOICE_ENCODER
CFLAGS = $(SPEEXOPTS) $(INCLUDES) -O3 -fomit-frame-pointer -Wno-unused-parameter
# This sets up 'SRC' based on the files mentioned in SOURCES
SRC := $(shell cat $(SPEEXSRC)/SOURCES | $(CC) $(CFLAGS) -E -P - | grep -v "^\#")
SOURCES = $(SRC:%.c=$(SPEEXSRC)/%.c) rbspeexenc.c
OBJS := $(SRC:%.c=%.o) rbspeexenc.o
DEPFILE = dep-speex
DIRS =
.PHONY : all
all: ../rbspeexenc
$(DEPFILE): $(SOURCES)
$(SILENT)rm -f $(DEPFILE)
$(SILENT)(for each in $(SOURCES) x; do \
if test "x" != "$$each"; then \
obj=`echo $$each | sed -e 's/\.[cS]/.o/' | sed -e 's/^.*\///' `; \
$(CC) -MG -MM -MT "$$obj" $(CFLAGS) $$each 2>/dev/null; \
fi; \
if test -n "$$del"; then \
rm $$del; \
del=""; \
fi \
done > $(DEPFILE); \
echo "oo" > /dev/null )
../rbspeexenc: $(OBJS) $(DEPFILE)
gcc -o ../rbspeexenc $(OBJS) -lm
%.o:
$(CC) $(CFLAGS) -c $< -o $@
clean:
rm -f $(OBJS) dep-speex
-include $(DEPFILE)