Having recently moved back to a Linux machine (running Ubuntu 11.04) I had a few things to get working to be back to working at full speed without needing to use my Windows XP virtual machine all the time. One of these things was access to the iSeries that we use as our development and live machines.
IBM now provide an RPM based installer for IBM iSeries Access that can be downloaded from the IBM website (login required). Once downloaded the first step is to convert this into a package that is usable on Debian based systems. The utility 'Alien' will convert an RPM into a DEB allowing it to be installed on Ubuntu. All of this needs doing as root (I think anyway … I couldn't get it to work as a standard user) so:
sudo -i
Install some required packages using apt-get or your chosen package manager:
apt-get install alien dpkg-dev debhelper build-essential libmotif-dev libmotif4 libmotif-dbg xfonts-scalable xfonts-utils xfonts-100dpi xfonts-75dpi msttcorefonts -y
Use alien to convert and install the rpm:
alien -i iSeriesAccess-7.1.0-1.0.i386.rpm -cv
Then add some links in order for the relevant packages to be where iSeries Access expects them:
ln -sf /usr/lib/libXm.so.4 /usr/lib/libXm.so.3
ln -sf /opt/ibm/iSeriesAccess/lib/libcwbcore.so /usr/lib/libcwbcore.so
ln -sf /opt/ibm/iSeriesAccess/lib/libcwbrc.so /usr/lib/libcwbrc.so
As I am using en_GB as my locale and it doesn't seem to fully exist when installed I needed to generate it:
locale-gen en_GB
Once this was done I was able to start either
/opt/ibm/iSeriesAccess/bin/ibm5250 -LANGID en_GB
/opt/ibm/iSeriesAccess/bin/setup5250 -LANGID en_GB
Because I had to install as root I need to run as root in order to pick up the config files created by setup5250. I created a script lauch5250:
#!/bin/bash
/opt/ibm/iSeriesAccess/bin/setup5250 -LANGID en_GB
and then added a launcher that runs launch5250 with sudo automagically:
gksudo /opt/ibm/iSeriesAccess/bin/launch5250
This may not be the neatest or the most 'correct' way to get this working, but it works and I couldn't find a better solution online.