I am relatively new to Apple OS and thus am not able to figure out as to how do I download, install then set up Java speech jar files and set up the classpath.
I tried everything possible from
- Downloading FreeTTS,jsapi and trying to add the jsapi.jar to /library/extensions folder
- Trying to use chmod command
- Trying to open the jar file (which returned an error and asked me to check console)
- Tutorials asking me to drop jar into the "lib" folder (I can't really figure out what and where is the "lib" folder in mac)
Basically I want to use all the capabilities of javax.speech in my Java programs.
Download FreeTTS. Extract. Open the extracted /lib folder.
chmod +x ./jsapi.sh
and afterwardssh ./jsapi
. Read the BCEL and accept.As you can see there is the
jsapi.jar
being extracted into the lib folder (which was not there before). Now you can add the lib folder (it says it will be enough to point to the lib/freetts.jar) to your class path of any application that is using FreeTTS.You could add it into some directory in your userspace folder and add to your
~/.bash_profile
the lineexport JS_API_HOME=~/the/path/lib
where~/the/path
would be where you stored the extracted archive. Then, you have to add the environment variable$JS_API_HOME
to every build/classpath where you want to use the library.For example,
java -cp $JS_API_HOME -jar moep.jar