Peeyush
Peeyush

Reputation: 11

How to link festival TTS libraries in a C++ programme using g++

i am using Festival c++ Api but in the manual provided at

http://www.cstr.ed.ac.uk/projects/festival/manual/festival_28.html#SEC132

saying to link festival/src/lib/libFestival.a etc. so please tell me hw to link them with my c++ programme

Upvotes: 1

Views: 1351

Answers (2)

Dennis Do
Dennis Do

Reputation: 480

I assume that you put your file.cpp in the directory containing festival and speech_tools which are extracted from packages.

compile:

g++ yourFile.cpp -o yourFile -I./festival/src/include -I./speech_tools/include -L./festival/src/lib -lFestival -L./speech_tools/lib/ -lestools -lestbase -leststring

Upvotes: 0

anon
anon

Reputation:

The simplest way to link a static library from g++ is simply to name the library on the command line, using the complete path:

g++ mycode.cpp -o myprog /myinstall/festival/src/lib/libFestival.a

where /myinstall is wherever you installed the libraries. You can also specify the path and the library with the -L and -l flags:

g++ mycode.cpp -o myprog -L/myinstall/festival/src/lib -lFestival

Upvotes: 1

Related Questions