Mwalk is distributed as a gzipped tar archive. To unpack the distribution you will need access to a current version of tar and gzip. Assuming the file is ./mwalk-0.1.0.tgz, you can extract the distribution tree by typing:
$ gunzip mwalk-0.1.0.tgz
$ tar xf mwalk-0.1.0.tar
or, if you have GNU tar:
$ tar xzf mwalk-0.1.0.tgz
Mwalk comes with a configuration script that automatically detects many pecularaities of your system and creates make files accordingly. Details of the configure script are explained in INSTALL which should be included with the package. In short, the process consists of running the configure script then running make to build and possibly install the package.
In the package directory type:
and if you want to install the package, type:
$ make install
During configuration, the script will attempt to find the path to java binaries. If it cannot find them automatically or if you would like to indicate a different path, pass the --with-jdk or --with-java options. The former assumes that the standard jdk directory exists at the indicated path, including bin and lib sub-directories. The latter, indicates an explicit directory which contains just the java binaries. Another option, --enable-jdk-home, allows the user to circumvent the normal search order by supplying a path to the jdk through $JDK_HOME.
By default, the package does not create API documentation. This can take some time to compile and requires javadoc. To enable this feature include the --enable-api option. To view the entire set of available options, type:
$ ./configure --help
The distribution tree consists of seven directories:
|src||java and perl source tree|
|bin||main application script|
|etc||base config file and java policy file|
|lib||destination for .jar files|
|doc||general documentation and javadoc api|
|class||destination for .class files (created by configure)|
Mwalk consists primarily of two java applications (Builder and Animator) and three perl scripts (generate.pl, parse.pl and upath.pl). However, a single shell script, mwalk, is supplied which runs the correct "application" within the appropriate environment. See the next section (running mwalk) for more details.
The java applications depend on a number of support classes. Five java packages are defined in src:
When building mwalk, these classes are combined into two jar files, mwalk-core.jar and mwalk-app.jar. The jar files are installed and the `mwalk' script automatically places them in your classpath. If you do not follow the basic installation procedures then you will need to ensure that these archives are available.
The perl scripts depend on a number of custom modules which are located in lib/Mwalk. The path prior to the `Mwalk' directory must be passed to perl via the -I option when running the scripts. The scripts themselves are not executable. Instead you should use the main `mwalk' script which will include the search path automatically.
When the package is installed, the installation path is burned into the `mwalk' script. If you move the package after installation, this path will be incorrect. The script does attempt to handle this situation to some degree by inspecting the script's execution path as well as trying the $MWALK_HOME environment variable.