John Bokma MexIT
freelance Perl programmer

Installing Saxon-HE 9.3 manually on Lucid Lynx

Monday, July 4, 2011 | 0 comments

Because Ubuntu didn't see my manual installation of the Oracle Java JDK as a valid Java alternative I couldn't install Saxon-B using apt-get install. Instead of trying to find a solution to this issue I decided to install Saxon manually as well. And since I was now free in my choice, I decided to install the more recent Saxon Home Edition version 9.3.

Below follows a HOWTO of how I installed Saxon-HE version 9.3 successfully on Ubuntu 10.04 LTS.

Downloading Saxon-HE

Click the "Download for Java" link under the Saxon-HE 9.3 section on The SAXON XSLT and XQuery Processor page hosted at SourceForge.

After the download had finished I generated the MD5 digest. While no such digest is given on the Saxon page itself I publish the result here for reference.

cd ~/Downloads

Installing Saxon-HE

After the download has finished extract the zip file into /usr/share/java and clean up as follows:

sudo mv ~/Downloads/ /usr/share/java
cd /usr/share/java
sudo unzip 
sudo rm 

Next, create two shell scripts, one to use Saxon HE as a XSLT processor and one to use Saxon HE as an XQuery processor. Name the first script saxon9he-xslt and save it into /usr/bin, for example using sudo vi /usr/bin/saxon9he-xslt, and copy the following lines into it:


exec java -cp /usr/share/java/saxon9he.jar net.sf.saxon.Transform "$@"

Name the second script saxon9he-xquery and save it into /usr/bin as well. Copy the following lines into this file:


exec java -cp /usr/share/java/saxon9he.jar net.sf.saxon.Query "$@"

When done, make both files executable as follows:

sudo chmod 755 /usr/bin/saxon9he-xslt
sudo chmod 755 /usr/bin/saxon9he-xquery

Now if you enter saxon9he-xslt on the command line you should get the following warning.

No source file name

Followed by a message that gives the possible options and parameters.

Verify that saxon9he-xquery gives a similar output but that while saxon9he-xslt refers to net.sf.saxon.Transformsaxon9he-xquery should refer to net.sf.saxon.Query.

Saxon and XSLT related

Also today

Please post a comment | read 0 comments | RSS feed