Explains how to install and use the Windward Java Engine in Linux. This tutorial specifically uses Ubuntu 12.04, but the steps should work on any Linux system with little extra effort.
After completing this tutorial you will have installed the Windward Java Engine on a Linux system, and have a working knowledge of running Java programs that use the engine.
Install the JDK
The first thing needed is a JDK (Java Development Kit) installation. This isn't too hard to come by, but depending on your distribution of Linux, this step might be slightly different.
In Ubuntu 12.04, the package is openjdk-6-jdk (or default-jdk) which can be installed with the following command:
$ sudo apt-get install openjdk-6-jdk
The Oracle JDK isn't available in the default repositories on some systems, which is why we use OpenJDK here. There are guides on the internet that show you how to get the correct PPA repositories set up to get the Oracle JDK, should you need that option.
For other systems, such as Debian, Fedora, or any other flavor of Linux, this command will be different but it should be pretty straightforward if you are familiar with your operating systems package manager.
Download & Setup the Engine
This step is the meat of this tutorial. The engine is available from the downloads page, so we'll get that
$ wget http://windward.net/downloads/SetupWindwardReportsJava.zip
We're going to install it to /opt/windward to make things easy. In the shown command, replace marcusj with your username.
$ sudo mkdir /opt/windward $ sudo chown marcusj /opt/windward $ unzip SetupWindwardReportsJava.zip -d /opt/windward
$ sudo cp /opt/windward/jars/* /usr/share/java
And of course, tell Java where to find them. We're adding it to the /etc/environment file for future use. The export command allows us to work with it during this session.
$ sudo cp /etc/environment /etc/environment.bk $ printf "CLASSPATH=\".:/usr/share/java/*\"\n" | sudo tee -a /etc/environment $ export CLASSPATH=.:/usr/share/java/*
$ cd /opt/windward/demo/Samples/Java/CommandLine/src $ cp ../WindwardReports.properties . $ vi WindwardReports.properties $ javac RunReport.java $ java RunReport ../samples/InvoiceTemplate.docx Invoice.pdf -xml ../samples/Order.xml.
We set up the Windward Java Engine in a Linux installation here. Now you can move on to set up a Java servlet with Tomcat 6 and our Servlet sample!