From 65458ee71ca741fbed1bff7e358760bb480b85e9 Mon Sep 17 00:00:00 2001 From: Thom Johansen Date: Fri, 16 Nov 2007 15:35:37 +0000 Subject: 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 --- tools/rbspeex/Makefile | 56 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 tools/rbspeex/Makefile (limited to 'tools/rbspeex/Makefile') diff --git a/tools/rbspeex/Makefile b/tools/rbspeex/Makefile new file mode 100644 index 0000000000..4771fe4ea2 --- /dev/null +++ b/tools/rbspeex/Makefile @@ -0,0 +1,56 @@ +# __________ __ ___. +# 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) -- cgit