How to setup your very own wapplet

Terms Used in this document:

wapplet - WAVE applet - a java applet that allows you to access PV-WAVE from a WWW server. wapplet archive - or wapplet.tar.Z wapplet directory - the directory you want to extract the wapplet archive into. cgi-bin URL - the http address of the cgi-bin directory or the directory of your http server that allows binary executions.

Things you must have installed:

- An http server - RogueWave's PV-WAVE - JDK: java development kit (java compiler from SUN) - C compiler

Things to get to set up the wapplet:

- (zip file) or wapplet.tar.Z (tar-compressed file) - cgiparse.Z (executable for SUN4 OS that no longer exists) - (from Visual Numerics, that longer exists) Make a directory that can be accessed through your http server and place the archives you downloaded in the diretory.

Extract the wapplet archive and make the following Changes:

Before you begin look at the README file that comes in the wapplet archive. cgiparse: - Uncompress into the wapplet directory. - Give execute permissions. - Update cgi-bin URL in line: 'URL url = new URL("someone_else's_URL/call_wave");' (note - call_wave must remain in the URL line) - After line 'URLConnection connection = url.openConnection();' Add lines 'connection.setDoOutput(true);' 'connection.setDoInput(true);' call_wave: - Must be in the cgi-bin directory. (or a directory that can accessed by the http server) - Change JAVA_UTILS to the ("wapplet directory"/server) path where "waveserver" can be found once it has been compiled. - Change CGI-UTILS to the wapplet directory where "cgiparse" can be found. - Give execute permissions. server/Makefile: - Change 'CC = their_path' to 'CC = Your_Path' Your_Path should be the path to your C-compiler. server/waveserver.h: - Change the HOSTNAME "variable" to the server's host name. ie..if the name of the machine is '' then the host name is 'wave'. - Change the USER "name" to the name of the user that is defined, under the http server, to execute files in the cgi-bin directory. - Change the START_CMD "path" to be the exact path and filename for the java_server unix script. java_server: - Edit your JAVA_UTILS enviroment varriable to be the path to the wapplet directory where wavestartup can be found. - Edit the path in 'source /depot/client/beauty/data2/james/wave/bin/wvsetup' to be the exact path to wvsetup on your machine (requires wave installed). - Move the line 'setenv WAVE_PATH ${JAVA_UTILS}:${WAVE_PATH}' after the line 'source /path-to-wave/wvsetup'. - Give java_server execute permissions. - Change line "path = '/Some_Body_else's_path/'" to the path of your wapplet directory. (note - the path must end with a '/') - Add line '..locals 50' after the 'PRO JAVA_SERVER' line. where 50 is the number of local variables you need. (50 is usually a safe amount)

Things to compile:

	- Delete the old 'waveserver'
	- Go into the 'wapplet directory'/server directory and type 'make'.
	- Give waveserver execute permissions.

	- Compile the file by executing 'javac' from the
	  wapplet directory.