This file describes how to set up your environment to run Artisynth 2.X, a modeling environment for articulatory speech synthesis. PREREQUISITES ------------- Sun Java SE JDK 5.0 (no need for NetBeans or JAVA EE) http://java.sun.com/javase/downloads/index_jdk5.jsp or Sun Java SE JDK 6.0 (no need for NetBeans or JAVA EE) http://java.sun.com/javase/downloads/index.jsp or IBM J2SE 5.0 http://www-128.ibm.com/developerworks/java/jdk/linux/download.html or Apple J2SE 5.0 http//www.apple.com/java/ Ensure that your PATH environment variable includes the jdk1.5_xx/bin directory. RUNNING ARTISYNTH ----------------- - for Windows 2000/XP Execute the batch file bin/artisynth.bat - for Linux, Mac OSX or Windows 2000/XP with Cygwin Execute the shell script bin/artisynth Use the command line option -help to see options to change the default startup behavior. AUTOMATIC ENVIRONMENT SETUP FOR DEVELOPERS ------------------------------------------ - for Linux, Mac OSX, or Windows 2000/XP with Cygwin using sh, bash, or zsh shell source the in your shell script: source ./bin/artisynth -env ALTERNATIVE MANUAL ENVIRONMENT SETUP FOR DEVELOPERS --------------------------------------------------- 1) Set the environment variable ARTISYNTH_HOME to the path name of the root Artisynth directory (i.e., the directory contains this README file) 2) Set the environment variable ARTISYNTH_PATH to a search path (i.e., list of directories) for Artsiynth config files. A good default value for ARTISYNTH_PATH is the current directory (".") and the Artisynth root directory. 3) Set your CLASSPATH to reference the following .jar files in $ARTISYNTH_HOME/lib: jogl.jar # java open GL bindings, supported by Sun # (see https://jogl.dev.java.net) argparser.jar # command line argument parsing # (see http://www.cs.ubc.ca/~lloyd/java/argparser.html) jass.jar # Java Audio synthesis system # (see http://www.cs.ubc.ca/~kvdoel/jass) quickhull3d.jar #? jmf.jar # Java Media Framework 4) Set your CLASSPATH to also include $ARTISYNTH_HOME/classes 5) Set your PATH environment variable to include $ARTISYNTH_HOME/bin 6) This is optional unless you get UnsatisfiedLinkError exception 6a) On Windows, set your PATH environment variable to also include $ARTISYNTH_HOME/lib/Windows 6b) On Linux, set your LD_LIBRARY_PATH environment variable to include $ARTISYNTH_HOME/lib/Linux 6c) On Mac systems, set your LD_LIBRARY_PATH and DYLD_LIBRARY_PATH environment variables to include $ARTISYNTH_HOME/lib/Darwin-xxx 6d) Alternativly to environment you could pass -Djava.library.path to the jvm EXAMPLE SETUP FOR LINUX CSH/TCSH -------------------------------- setenv ARTISYNTH_HOME $HOME/artisynth/artisynth_2_0 setenv ARTISYNTH_PATH ".":$ARTISYNTH_HOME setenv LD_LIBRARY_PATH "$ARTISYNTH_HOME/lib/Linux":$LD_LIBRARY_PATH setenv CLASSPATH "$ARTISYNTH_HOME/lib/jogl.jar":$CLASSPATH setenv CLASSPATH "$ARTISYNTH_HOME/lib/argparser.jar":$CLASSPATH setenv CLASSPATH "$ARTISYNTH_HOME/lib/jass.jar":$CLASSPATH setenv CLASSPATH "$ARTISYNTH_HOME/lib/quickhull3d.jar":$CLASSPATH setenv CLASSPATH "$ARTISYNTH_HOME/lib/jmf.jar":$CLASSPATH setenv CLASSPATH "$ARTISYNTH_HOME/classes":$CLASSPATH EXAMPLE SETUP FOR LINUX SH (Bourne shell) ----------------------------------------- ARTISYNTH_HOME=$HOME/artisynth/artisynth_2_0 export ARTISYNTH_HOME ARTISYNTH_PATH=".":$ARTISYNTH_HOME export ARTISYNTH_PATH LD_LIBRARY_PATH="$ARTISYNTH_HOME/lib/Linux":$LD_LIBRARY_PATH export LD_LIBRARY_PATH # should already be exported ... CLASSPATH="$ARTISYNTH_HOME/lib/jogl.jar":$CLASSPATH CLASSPATH="$ARTISYNTH_HOME/lib/argparser.jar":$CLASSPATH CLASSPATH="$ARTISYNTH_HOME/lib/jass.jar":$CLASSPATH CLASSPATH="$ARTISYNTH_HOME/lib/quickhull3d.jar":$CLASSPATH CLASSPATH="$ARTISYNTH_HOME/lib/jmf.jar":$CLASSPATH CLASSPATH="$ARTISYNTH_HOME/classes":$CLASSPATH export CLASSPATH # should already be exported ... EXAMPLE SETUP FOR Windows with Cygwin bash ------------------------------------------ export A=$HOME/eclipse/workspace/artisynth_2_0 export ARTISYNTH_HOME=Z:/eclipse/workspace/artisynth_2_0 export PATH=$PATH:$A/lib/Windows:$A/bin export ARTISYNTH_PATH=$ARTISYNTH_HOME export CLASSPATH="$CLASSPATH;$ARTISYNTH_HOME/lib/jogl.jar;$ARTISYNTH_HOME/lib/argparser.jar;$ARTISYNTH_HOME/lib/jass.jar;$ARTISYNTH_HOME/lib/quickhull3d.jar;$ARTISYNTH_HOME/lib/jmf.jar;$ARTISYNTH_HOME/classes" EXAMPLE SETUP FOR Windows 2000/XP with Cygwin tcsh -------------------------------------------------- Download the CYGWIN utilities from http://www.cygwin.com. Make sure to get the make utilities and the tcsh shell. setenv A "/cygdrive/d/aakees/ubc/artisynth/artisynth_2_0" setenv ARTISYNTH_HOME "d:/aakees/ubc/artisynth/artisynth_2_0" setenv CLASSPATH ".;$ARTISYNTH_HOME/classes;$ARTISYNTH_HOME/lib/jogl.jar;$ARTISYNTH_HOME/lib/jass.jar;$ARTISYNTH_HOME/lib/quickhull3d.jar;$ARTISYNTH_HOME/lib/jmf.jar;$ARTISYNTH_HOME/lib/argparser.jar;$CLASSPATH" setenv PATH "$PATH:/cygdrive/d/jdk1.5.0/bin:$A/lib/Windows" NB: Make sure to run java.exe from jdk1.5, NOT from the jre otherwise JavaSound will not work properly and the server option won't be availible! You may need to put JDK in front of your windows system32 in your windows PATH setup (MyComputer->Properties->Advanced->Environment Variables). Type "which java" in your tcsh to see which java you are using. In addition you need to put your cygwin/bin in front of the Window/System to select the CYGWIN version of UNIX utils used in the makefile instead of the Windows version. EXAMPLE SETUP FOR Windows 2000/XP using command prompt --------------------------------------------- Download the CYGWIN utilities from http://www.cygwin.com if you want to compile with the makefile. You don't need CYGWIN unless you want to use the makefile provided. MyComputer->Properties->Advanced ->Environment Variables Select "New" and add the following variables (or edit them if you already have the variable defined). ARTISYNTH_HOME d:\aakees\ubc\artisynth\artisynth_2_0 ARTISYNTH_PATH .;d:\aakees\ubc\artisynth\artisynth_2_0 CLASSPATH .;%ARTISYNTH_HOME%\classes;%ARTISYNTH_HOME%\lib\jogl.jar;%ARTISYNTH_HOME%\lib\argparser.jar;%ARTISYNTH_HOME%\lib\jass.jar;%ARTISYNTH_HOME%\lib\quickhull3d.jar;%ARTISYNTH_HOME%\lib\jmf.jar You should have a variable Path already defined. You need to add %ARTISYNTH_HOME%\lib\Windows to it. Here's an example: d:\cygwin\bin;d:\jdk1.5.0\BIN;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\system32\WBEM;%ARTISYNTH_HOME%\lib\Windows Note that d:\jdk1.5.0\BIN and the CYGWIN utils come before the Windows stuff. To run ArtiSynth, just type java artisynth.core.driver.Main in your DOS shell. EXAMPLE SETUP FOR Mac OSX 10.4 (tiger) -------------------------------------- The environment setup is the same as for Linux for either bash or tcsh. Note that you require Mac OSX 10.4 tiger and need to install j2sdk 1.5 and make it the default Java version: $ cd /System/Library/Frameworks/JavaVM.framework/Versions $ sudo mv CurrentJDK CurrentJDK.old $ sudo ln -s 1.5 CurrentJDK make comes with the Developer tools or with fink -------------------------------- RUNNING THE MAIN DRIVER PROGRAM ------------------------------- If your environment is set as described above, you should be able to run Artisynth from any directory. The main driver program can be invoked as follows: % java artisynth.core.driver.Main On UNIX systems, you can also invoke the driver program with the script % artisynth provided you have $ARTISYNTH_HOME/bin in your executable path, as described above. IF YOU ARE USING ECLIPSE ------------------------ Make sure you have eclipse 3.1 or greater and java sdk 1.5. Checkout the artisynth_2_0 project as usual. Unzip the file $ARTISYNTH_HOME/eclipseProject.zip into $ARTISYNTH_HOME; this contains default settings for the eclipse files .project and .classpath In java perspective Highlight the artisynth_2_0 in the Package Explorer: 1) In Menu project > properties > Java Compiler: - check box labelled "Enable Project Specific Settings" - change "Compiler Compliance Level" to "5.0" 2) In Menu project > properties > Java Build Path: - check box labelled "JRE System Library [jre1.5.0_XX] 3) Some model need more then the default stack memory - add -Xmx256m to Run > Run.. > Arguments > VM Arguments To use the jogl libraries you have alternatives A. add native libraries to your library path with environment variables Windows: PATH ARTISYNTH_HOME/lib/Windows Linux : LD_LIBRARY_PATH ARTISYNTH_HOME/lib/Linux Mac Osx: DYLD_LIBRARY_PATH ARTISYNTH_HOME/lib/Darwin B. copy native libraries to your system Windows: cp ARTISYNTH_HOME/lib/Windows/* JRE_PATH/lib/ext MacOsx: cp ARTISYNTH_HOME/lib/Darwin/* ~/Library/Java/Extensions Linux: cp ARTISYNTH_HOME/lib/Linux/* JRE_PATH/lib/ext C. add library path in eclipse to each run target You need to modify the run configuration by editing the menu: Run > Run > MassSpringDemo > Environment > new Variable Value Windows: PATH ${project_loc}/lib/Windows Linux : LD_LIBRARY_PATH ${project_loc}/lib/Linux MAC OSX: DYLD_LIBRARY_PATH ${project_loc}/lib/Darwin