Paul's Debian Unix How To



Abstract

This document describes how I installed FoundationStone (and the required JRE) as a non-root user on my Debian Linux system. It is based on FoundationStone's own Unix Installation Help page and my own experiences fighting with Java and X fonts.

Note that:

1. collect the JRE from Sun:
http://java.sun.com/j2se/ (My version was J2SE 1.4.2)

1a. chdir to an appropriate place to extract (perhaps your home directory, or /usr/local if root). The download from Sun is an auto-extracting shell-script, so execute it with the following command (this will create its own directory structure, in my case ~/j2re1.4.2_02):
sh j2re-1_4_2_02-linux-i586.bin

2. collect FoundationStone (*nix version) from foundationstone.com.au (in my case FoundationStone_2.1.1.tar.gz)

2a. chdir to an appropriate place and extract:
tar xzf FoundationStone_2.1.1.tar.gz

3. Fonts. (For more detail, please see http://pegasus.rutgers.edu/~elflord/font_howto. The Linux Documentation Project [www.tldp.org] may also have a copy.)

I choose to leave the fonts within the FoundationStone structure. (Ed: Some VM's can load these fonts directly in, and expect to see them there). We basically have to tell the X font server where these are...

3a. My system needed .pfa files, so I symlinked to the .ps files provided:
cd <FoundationStone_Directory>/Fonts
ln FoundationHebrew.ps FoundationHebrew.pa -s
ln FoundationHebrewScript.ps FoundationHerewScript.pfa -s

3b. Create the fonts.dir and fonts.scale file for these fonts in the FoundationStone Fonts directory. The files are identical, so put the following three lines into fonts.dir and symlink fonts.scale to it:

fonts.dir:
FoundationHebrew.pfa -unknown-foundationhebrew-medium-r-normal--0-0-0-0-p-0-adobe-fontspecific
FoundationHebrewScript.pfa -unknown-foundationhebrewscript-medium-r-normal--0-0-0-0-p-0-adobe-fontspecific

ln fonts.dir fonts.scale -s

3c. Now add the new fonts onto your font path (note, use a fully-qualified-path). If you are in the FoundationStone Fonts directory, just use the following:
xset +fp `pwd`

3d. Reload the font server:
xset fp rehash

4. Test FoundationStone. Less typing if you chdir to FoundationStone's JavaSupport directory (note that my JRE is rooted off my home directory):

cd <FoundationStone_Directory>/JavaSupport
~/j2re1.4.2_02/bin/java -classpath FoundationStone.jar:collections.jar:plot.jar au.com.foundationstone.ui.FSLauncher

Note: In my case, I found that part of the window did not draw until I caused a resize event (ie: try to resize the window)

5. Create a script to automate all of the above. I have a ~/bin directory where I keep scripts. (Debian systems automagically add ~/bin to your path if it exists.) I put these commands in ~/bin/foundationstone (remember to adjust paths for your system):
#!/bin/bash
xset +fp $HOME/FoundationStone_2.1/Fonts
xset fp rehash
cd $HOME/FoundationStone_2.1
$HOME/j2re1.4.2_02/bin/java -classpath JavaSupport/FoundationStone.jar:JavaSupport/collections.jar:JavaSupport/plot.jar
au.com.foundationstone.ui.FSLauncher &

Remember to chmod your script to be executable:
chmod u+x ~/bin/foundationstone

Useful Resources/Utilities:
The Linux Documentation Project (www.tldp.org)

xfontsel - the X Font Selector - browse your available fonts

xlsfonts - list available fonts

I trust this document assists you in meeting your "primary objective" (aka learning Hebrew) rather than spending all your time hacking... best of luck all...

paulusm @ telstra dot com
2003-10-27



left arrow 

web analytics