Build Instructions

Source: gzipped tarball, bzip2ed tarball zipfile

Linux/*nix

The procedure should be the same for any UNIX flavor with a modern JDK/JRE. the Sun 1.3 or 1.2.x JDK should work, though only JDK1.3 has been tested.

  1. Download the source tarball (preferable to a zipfile, since zip does not properly preserve case. The tarball will create a subdirectory 'draw' containing the entirety of the project.

    In Netscape, you can save the file by shift-clicking on the link. From the shell prompt, run wget http://www.devin.com/cruft/cs360/draw/draw-final.tar.gz.

  2. Unpack the tarball as follows:

    
    [user@host ~] % tar xzvf draw-final.tar.gz
    draw/
    draw/lineShape.java
    draw/Shape.java
    draw/ShapeList.java
    draw/Tool.java
    ...
    draw/showRNCommand.java
    draw/helpMenuRequest.class
    draw/static/
    draw/static/releasenotes.html~
    draw/static/releasenotes.html
    draw/static/releasenotes.html,v
    

  3. Change to the newly-created draw directory:

    [user@host ~] % cd draw
    [user@host ~/draw] %
    

  4. Ensure that your CLASSPATH environment variable is set properly, and that the PATH variable includes the proper path to the JDK (/usr/local/jdk/ assumed here):

    
    [user@host ~/draw] % PATH=/usr/local/jdk/bin:$PATH
    [user@host ~/draw] % export CLASSPATH=/usr/local/jdk:.
    

  5. Compile the project:

    [user@host ~/draw] % javac *.java
    

  6. Run the project:

    [user@host ~/draw] % java draw
    

    Assorted font errors will occur here -- this appears to be a configuration issue in the JDK, but does not have overt adverse effects.

  7. To inspect a save file, open it in a pager (e.g. less) or an editor (e.g. vi,emacs,gnp, gedit, etc.); here assuming the sample file samples/demo1.draw:

    [user@host ~/draw] % gnp samples/demo1.draw