2000-01-05 08:20:27 +00:00
|
|
|
#
|
|
|
|
# Makefile for LPC-10 speech coder library (unix)
|
|
|
|
#
|
|
|
|
|
|
|
|
# default C compiler
|
2004-06-22 17:42:14 +00:00
|
|
|
CC?= gcc
|
2000-01-05 08:20:27 +00:00
|
|
|
|
|
|
|
#
|
|
|
|
# These definitions for CFLAGS and LIB_TARGET_DIR are used when one
|
|
|
|
# runs make in the lpc10 directory, without environment variables that
|
|
|
|
# override them. When make is run in this directory from a makefile
|
|
|
|
# for an application that uses the LPC10 coder, there are environment
|
|
|
|
# variables set for CFLAGS and LIB_TARGET_DIR that override these
|
|
|
|
# definitions.
|
|
|
|
#
|
|
|
|
|
|
|
|
LIB_TARGET_DIR = .
|
|
|
|
|
|
|
|
#
|
|
|
|
# -I$(LIB_TARGET_DIR) option needed so that #include "machine.h"
|
|
|
|
# directives can find the machine.h file.
|
|
|
|
#
|
|
|
|
|
|
|
|
WARNINGS = -Wall -Wno-comment -Wno-error
|
2004-06-22 17:42:14 +00:00
|
|
|
CFLAGS += $(OPTIMIZE) -I$(LIB_TARGET_DIR) $(WARNINGS) -fPIC
|
2003-03-18 06:00:18 +00:00
|
|
|
#CFLAGS+= $(shell if uname -m | grep -q 86; then echo "-mpentium" ; fi)
|
2003-03-28 21:36:52 +00:00
|
|
|
|
2004-08-31 03:31:59 +00:00
|
|
|
#fix for PPC processors and ALPHA, And UltraSparc too
|
2003-10-26 18:50:49 +00:00
|
|
|
ifneq ($(OSARCH),Darwin)
|
2004-06-22 17:42:14 +00:00
|
|
|
ifneq ($(findstring BSD,${OSARCH}),BSD)
|
2003-03-28 21:36:52 +00:00
|
|
|
ifneq ($(PROC),ppc)
|
2004-01-08 16:52:11 +00:00
|
|
|
ifneq ($(PROC),x86_64)
|
2004-03-15 16:51:58 +00:00
|
|
|
ifneq ($(PROC),alpha)
|
2004-08-31 16:33:00 +00:00
|
|
|
#The problem with sparc is the best stuff is in newer versions of gcc (post 3.0) only.
|
|
|
|
#This works for even old (2.96) versions of gcc and provides a small boost either way.
|
|
|
|
#A ultrasparc cpu is really v9 but the stock debian stable 3.0 gcc doesn.t support it.
|
|
|
|
#So we go lowest common available by gcc and go a step down, still a step up from
|
|
|
|
#the default as we now have a better instruction set to work with. - Belgarath
|
2004-08-31 03:31:59 +00:00
|
|
|
ifeq ($(PROC),ultrasparc)
|
2004-08-31 16:33:00 +00:00
|
|
|
CFLAGS+= -mtune=$(PROC) -mcpu=v8 -O3 -fomit-frame-pointer
|
2004-08-31 03:31:59 +00:00
|
|
|
else
|
|
|
|
CFLAGS+= -march=$(PROC)
|
|
|
|
endif
|
2003-03-28 21:36:52 +00:00
|
|
|
endif
|
2003-10-26 18:50:49 +00:00
|
|
|
endif
|
2004-01-08 16:52:11 +00:00
|
|
|
endif
|
2004-03-15 16:51:58 +00:00
|
|
|
endif
|
2004-06-22 17:42:14 +00:00
|
|
|
endif
|
2000-01-05 08:20:27 +00:00
|
|
|
|
|
|
|
LIB = $(LIB_TARGET_DIR)/liblpc10.a
|
|
|
|
|
|
|
|
.PHONY: all clean
|
|
|
|
|
|
|
|
all: $(LIB)
|
|
|
|
|
2003-10-27 20:00:41 +00:00
|
|
|
OBJ= f2clib.o analys.o bsynz.o chanwr.o dcbias.o decode.o \
|
|
|
|
deemp.o difmag.o dyptrk.o encode.o energy.o ham84.o \
|
|
|
|
hp100.o invert.o irc2pc.o ivfilt.o lpcdec.o lpcenc.o \
|
|
|
|
lpcini.o lpfilt.o median.o mload.o onset.o pitsyn.o \
|
|
|
|
placea.o placev.o preemp.o prepro.o random.o rcchk.o \
|
|
|
|
synths.o tbdm.o voicin.o vparms.o
|
|
|
|
|
|
|
|
$(LIB): $(OBJ)
|
|
|
|
$(AR) cr $@ $(OBJ)
|
|
|
|
ranlib $@
|
2000-01-05 08:20:27 +00:00
|
|
|
|
|
|
|
clean:
|
|
|
|
-rm -f *.o $(LIB)
|