SPSS 16 on the EEE PC
If you encounter an error in the SPSS 16 installer for Linux that says "No Java Runtime Environment (JRE) was found on this system", then I think I have the solution for you. The problem is that the installer does not properly run the bundled JRE that it installs in its own temporary directory. So, although the error sounds as though it's not finding your JRE, it's actually not finding its own JRE.
I'll start from the beginning, because this isn't the only part of the installation where I encountered errors.
A friend of mine asked me to install her copy of SPSS 16 for Linux on her EEE PC. She met all of the system requirements (aside from the screen resolution and minimum CPU speed), but still could not get the installation to work.
First I just tried to run the installer file, 'setup.bin', and the installer exited almost immediately. I scrolled up to find out that it could not find 'bc', the arbitrary precision calculator. So I followed the instructions here and installed bc with 'apt-get update; apt-get install bc'.
Then setup.bin failed with the message, "The directory /tmp does not contain enough space to extract temporary files. Please specify a temporary directory using the -is:tempdir option. Use the -is:help option for more information." So, I ended up using her 2 GB USB memory stick for the temporary directory (I reformatted it to use ext2). At this point, I was using './setup.bin -is:tempdir /media/D\:/tmp' for the setup command.
That failed as well, but this time with the message, "No Java Runtime Environment (JRE) was found on this system". I thought that was odd, so I ran './setup.bin -is:help' again and noticed that there was an '-is:javahome' option. So, I ran 'ls -la `which java`', and found that java was a symbolic link which pointed to /etc/alternatives/java, which was also a symbolic link pointing to /usr/lib/jvm/java-1.5.0-sun/jre/bin/java. Then I ran the installer again, and it failed with the same message. At this point, my setup command was './setup.bin -is:tempdir /media/D\:/tmp -is:javahome /usr/lib/jvm/java-1.5.0-sun/jre'.
I ran './setup.bin -is:help' again to see if somehow it could point me in the right direction, because the installation instructions were pretty horrible. I noticed the '-is:log' option, so I ran the setup again with the command './setup.bin -is:tempdir /media/D\:/tmp -is:javahome /usr/lib/jvm/java-1.5.0-sun/jre -is:log /media/D:\:/tmp/spss.log'. That gave me the hint at what was really happening. The log file ended with, "installing bundled JRE... Verifying... /media/D:/tmp/istemp2346224982367/_bundledJRE_/bin/java -cp /media/D:/tmp/istemp2346224982367/Verify.jar Verify java.vendor java.version Verification failed for /media/D:/tmp/istemp2346224982367/_bundledJRE_ using the JVM file /media/D:/tmp/istemp2346224982367/_bundledJRE_/jvm".
Sure enough, if I said '/media/D:/tmp/istemp2346224982367/_bundledJRE_/bin/java -cp /media/D:/tmp/istemp2346224982367/Verify.jar Verify java.vendor java.version', I would get the error message, "Error occurred during initialization of VM java/lang/NoClassDefFoundError: java/lang/Object".
I knew that this was a serious boo-boo on the part of whoever designed this installer (very poor quality control), so instead of hacking the jvm file during runtime, I thought I would try a different trick so that the various paths and environment variables where not messed up.
mount -o bind /media/D\:/tmp /tmp
This effectively gives me the storage space for -is:tempdir in /media/D\:/tmp, but allows programs to access /media/D\:/tmp from /tmp instead (the default place for -is:tempdir). Using only './setup.bin' this time, the setup proceeded past extracting the bundled JRE, verifying it, and extracting the installation archive, but then setup exited with the error, "The installer is unable to run in graphical mode. Try running the installer with the -console or -silent flag."
I knew that loss of X was pretty typical to using 'sudo', so I changed /etc/sudoers with the command 'visudo', and added "XAUTHORITY DISPLAY" to env_keep in the Defaults declaration. At that point, I had to end my sudo session and start a new one. I verified that XAUTHORITY and DISPLAY were preserved after I started my sudo session with 'sudo -s', 'env | grep "XAUTHORITY\|DISPLAY"'. At that point, all I had to do was close the terminal application, reopen it with Ctrl+Alt+t, start a sudo session with sudo -s, and run './setup.bin'. Then the installer worked perfectly. There are also a few patches to SPSS 16 for Linux as well, located here.
I haven't tried installing them yet, but hopefully they will work 'out of the box'.
I know that this wasn't a very short and sweet how-to, but ... well... I didn't write the installer script, and I didn't really feel like modifying it (which would probably be some kind of copyright violation if I redistributed it), so I thought I would just describe the fix for anyone to read. Hopefully the SPSS people will read this and fix this installation bug for their next release.
Install BC - The Arbitrary Precision Calculator
Format a USB memory stick with Ext2, use as tempdir
Mount tempdir (bind) at /tmp
Edit /etc/sudoers to preserve XAUTHORITY DISPLAY