On Wed, 3 Mar 1999, James Henstridge wrote:
> If you have a relatively standard python extension module, you could use
> the Makefile.pre.in/Setup.in setup to build the extension.
Well I didn't really planed to make a python interface to the
command recognizer programs in C. I doesn't follow the recent interface
guidelines of python never the less I can be used. I'll have to make some
examples....
The problem is that I want don't want to spend to much time in making
installation scripts. I just wan't to release this version so people can
see that you can do some word recognition with free software in linux and
that the pygnome bindings are really cool.
I hope in the future I will rewirte everything from scrath in a good
structured way, with some real time oriented digital signal processing
library and a nice python interface.
> If you may
> need to do autoconf type stuff (eg check for presence of
> libraries/headers), I would recommend using the automake setup I have for
> pygtk/gnome-python.
My question is do I need really all this stuff even if I'm not compiling
anything ???
But then again:
- I can use it so it can warn the user if it doesn't have
pygnome installed.
- Or I can used to make gnome aware that I'm installing gvoice so
it pears on the menu ????
> It also helps with install/bytecompiling of python
> modules.
>
> If you have any further questions about it, send another message.
THANK JAMES !!!!!!!!!!!!!!!!!! :-) or as I would say in spanish
MUCHAS GRACIAS JAIME !!!!!!!!!
I've just writen a simple Makefile with an install part.
I copies the necesary files to an install directory, /usr/local or
/opt in an icepick directory an the it make some symbolic links so
the programs are in the path.
Do you think it's enougth ??? (I really don't thik so, It's just
too trivial)
#-------------------------- START OF MAKEFILE ---------------------------
# Makefile speech recognition programs (get_smpl, get_vqs, recognize)
# Macros
CC=gcc
DEBUG=-g
# Only use with pgccCFLAGS = -D_NO_PROTO $(DEBUG) -mpentiumpro
CFLAGS=-D_NO_PROTO $(DEBUG)
LIBS=-lm # Math library
# this directory should be /usr/local/ or /opt/
INSTALLDIR=/home/gvoice/root/usr/local/
ICEPICKDIR=$(INSTALLDIR)icepick-0.1-a/
# Objects needed to compile any of the programs get_smpl, get_vqs,
recognize
OBJS=allocate.o basics.o lpc_lib.o
OBJS_AUDIO=audio_linux.o
# Objects needed to compile olny get_smpl and recognize (for socket
comms.)
OBJS_SOCKETS=sockets_lib.o gsNetPoll.o
#Objects only needed for compiling get_smpl
OBJS_SMPL=get_smpl.o
#Objects only needed for compiling get_vqs
OBJS_VQS=get_vqs.o
#Objects only needed for compiling recognize
OBJS_REC=recognize.o
OBJS_MARKOV=hmm_mult.o key_lpc.o
# Dependencies
all: get_smpl get_vqs recognize
get_smpl: $(OBJS_SMPL) $(OBJS) $(OBJS_PLOT) $(OBJS_AUDIO) $(OBJS_SOCKETS)
$(CC) $(CFLAGS) -o $@ $(OBJS_SMPL) $(OBJS) $(OBJS_PLOT)\
$(OBJS_AUDIO) $(LIBS) $(OBJS_SOCKETS)
get_vqs: $(OBJS_VQS) $(OBJS) $(OBJS_AUDIO)
$(CC) $(CFLAGS) -o $@ $(OBJS_VQS) $(OBJS) $(OBJS_AUDIO)
$(LIBS)
recognize: $(OBJS_REC) $(OBJS) $(OBJS_AUDIO) $(OBJS_MARKOV)
$(OBJS_SOCKETS)
$(CC) $(CFLAGS) -o $@ $(OBJS_REC) $(OBJS) $(OBJS_AUDIO) \
$(OBJS_MARKOV) $(OBJS_SOCKETS) $(LIBS)
# compile commands for individual objects
$(OBJS):
$(CC) $(CFLAGS) -c lib/$*.c
$(OBJS_AUDIO):
$(CC) $(CFLAGS) -c lib/$*.c
$(OBJS_SOCKETS):
$(CC) $(CFLAGS) -c lib/$*.c
$(OBJS_SMPL):
$(CC) $(CFLAGS) -c $*.c
$(OBJS_VQS):
$(CC) $(CFLAGS) -c $*.c
$(OBJS_REC):
$(CC) $(CFLAGS) -c $*.c
$(OBJS_MARKOV):
$(CC) $(CFLAGS) -c lib/$*.c
# Simple install
install:
mkdir $(ICEPICKDIR)
mkdir $(ICEPICKDIR)bin
mkdir $(ICEPICKDIR)lib
mkdir $(ICEPICKDIR)doc
cp gvoice.py get_smpl get_vqs recognize $(ICEPICKDIR)bin
cp gui.py data.py communication.py $(ICEPICKDIR)lib
cp INSTALL INSTALL.speech_rec README \
README.speech_rec COPYING TODO TODO.speech_rec \
$(ICEPICKDIR)doc
ln -s $(ICEPICKDIR)bin/gvoice.py $(INSTALLDIR)bin/gvoice.py
ln -s $(ICEPICKDIR)bin/get_smpl $(INSTALLDIR)bin/get_smpl
ln -s $(ICEPICKDIR)bin/get_vqs $(INSTALLDIR)bin/get_vqs
ln -s $(ICEPICKDIR)bin/recognize $(INSTALLDIR)bin/recognize
ln -s $(ICEPICKDIR)lib/gui.py $(INSTALLDIR)lib/gui.py
ln -s $(ICEPICKDIR)lib/data.py $(INSTALLDIR)lib/data.py
ln -s $(ICEPICKDIR)lib/communication.py \
$(INSTALLDIR)lib/communication.py
ln -s $(ICEPICKDIR)doc $(INSTALLDIR)doc/icepick-0.1-a
# Simple clean
clean :
rm -f *.o
rm -f get_smpl get_vqs recognize
#---------------------------END OF MAKEFILE-------------------------------
Thanks again for all the help James !!!!!!
To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]