README FOR IRAF VERSION 2.10.4 Linux/IRAF Version Revised May 1996 (Patch 2 added) Revised November 1996 (f2cbin patch) ----------------------------------------------------------------------------- 05Sep95 Initial V2.10.4 release 29May96 patch 2 - see "Patch 2" below 19Nov96 f2cbin patch added There was no patch1 for Linux/IRAF, the initial release included this patch. ----------------------------------------------------------------------------- 1. INTRODUCTION Linux/IRAF V2.10.4 is a port of the June 1995 IRAF V2.10.4 release to Linux. We used the June 1995 Slackware 2.3 release and a 1.2.11 kernel to build the IRAF distribution. The Linux/IRAF distribution should run on any PC that Linux runs on, but for the record our primary development system is a Gateway P5-90 PCI system with all SCSI disks and tapes (using the Adaptec 2940 SCSI controller), 32 Mb RAM, Mitsumi ATAPI IDE CDROM, ATI Mach64 graphics, and a 17" (which really measures 16") Vivitron (Sony) monitor. This Linux/IRAF release is part of the PC-IRAF project. Our plans are to initially port IRAF to Linux, BSD, and Solaris x86. This is in part an experiment to learn how the different versions of UNIX available for the PC compare. There is no comittment to continued support for any particular version of UNIX for the PC, we will support whatever is the most popular. The PC software situation is constantly changing and rapidly evolving. The Linux/IRAF release should install and run on any recent Linux system. Linux is evolving rapidly however, and there are a number of different Linux distributions out there - Slackware, Yggdrasil, Red Hat, WGS, and others. These are all basically the same thing and they all share the same Linux kernel but they differ in many details regarding what non-Kernel software is included and how it is configured. Linux is really only the Linux kernel, the rest of the software in a typical Linux distribution is a collection of other freely available software such as the GNU, FSF, Xfree86, etc., added by the people that built the distribution you are using. Linux is the software equivalent of the very modular, open PC hardware environment. There is no one stable Linux system like there is for the more controlled environment found on UNIX workstations. Our expectation is that the statically linked Linux/IRAF distribution will *run* on any recent Linux system, however problems are possible when trying to compile and link IRAF programs due to the potential for library conflicts arising from differences in the library software or GNU compilers found in the various Linux distributions. If you encounter problems please let us know. Not all Linux systems are the same! Linux/IRAF V2.10.4 is the exact same version of IRAF as in any other IRAF V2.10.4 distribution, e.g. for the Sun or the DEC/Alpha. This README assumes that the reader is already familiar with IRAF and has probably already done other IRAF installations. Although the basic installation procedure is summarized here, we emphasize mainly what is different about Linux/IRAF and other IRAF versions. 2. THE LINUX/IRAF DISTRIBUTION The Linux/IRAF distribution files available are as follows. Note that these large files appear in the archive as directories, e.g. "as.lnux.gen" is a directory containing the distribution file "as.lnux.gen.gz" split into a number of 0.5 Mb segments which can be concatenated to regenerate the original 13.8 Mb file. For the Linux/IRAF distribution all distribution files are compressed using Gnu-ZIP (gzip). Split File Size Kb Description as.lnux.gen 13835 All sources - everything except the binaries ss.lnux.gen 5355 Stripped sources - same as AS but pre-stripped ib.lnux.x86 9276 IRAF (core system) binaries nb.lnux.x86 11236 NOAO package binaries ib.lnux.z86 7395 Same as IB but executables are compressed nb.lnux.z86 7563 Same as NB but executables are compressed The file size in Kb shown in this table refers to the compressed tar distribution file, not to the system after the distribution file is installed. See "Disk Requirements" below for more information on disk usage. The Linux/IRAF distribution is available via anonymous FTP from iraf.noao.edu in the directory /iraf/v210/LNUX (ftp://iraf.noao.edu/iraf/v210/LNUX/). Mailed tape and CDROM distributions are also available at cost from NOAO, send mail to iraf@noao.edu for further information. 3. INSTALLING LINUX/IRAF The installation documentation for Linux/IRAF consists of both this README and the Linux/IRAF Installation Guide, file linuxiraf.ps.Z in the Linux distribution (LNUX). The installation procedure outlined below is a summary intended for folks who are already familiar with basic IRAF installation procedures and who want to know what is different about Linux/IRAF. The installation guide contains more detailed information on the standard installation procedures for IRAF on UNIX systems such as Linux. In addition the Linux/IRAF Site Manager's Guide (linuxsmg.ps.Z) provides additional information on configuring the system. 3.1 GET READY The first step in installing Linux/IRAF is to decide what you want to install and download the files. o Select either AS (all sources) or SS (stripped sources) First you should decide whether you want to install the full system including sources (AS distribution or "all sources") or the pre-stripped system (SS distribution or "stripped sources"). If you install the AS distribution you can strip it after installation, but if you have no use for the sources you may as well go ahead and install the SS distribution. o Select .x86 (normal) and/or .z86 (compressed) binaries The second option, which is currently unique to Linux/IRAF, is whether or not the IRAF executables are compressed using gzexe. See the discussion of the "compressed executable option" below for more details on this option. We recommend installing the normal uncompressed executables (the "linux" architecture) if you have lots of disk space, if IRAF will be used heavily on your system, or if multiple users will be using IRAF. The compressed executables (the "linuz" architecture) may be preferred if disk space is tight or IRAF is infrequently used. If in doubt you can install both architectures and experiment to see which is better suited to your system and usage patterns. The IRAFARCH environment variable can be set to "linux" or "linuz" before starting IRAF to select the architecture to be used. o Download the files. Either ftp the desired distribution files from iraf.noao.edu, or order a mailed distribution if network access is a problem. It may be simplest to simply mirror the distribution on your system, e.g. create "as.lnux.gen", "ib.lnux.x86" etc. directories in a scratch area somewhere on your system. The large distribution files are broken up into chunks so that you don't have to start over from scratch if there are network problems and the downloading gets interrupted for some reason. If there is any doubt about the transfer use the CHECKSUMS file provided to verify the split file checksums. 3.2 CREATE THE MAIN DIRECTORY TREE There are many options for installing the main components of IRAF but in practice life will be simpler if you arrange things as follows (this is the default directory structure assumed by IRAF): : iraf iraf system (AS or SS) irafbin bin.linux core system binaries (IB) noao.bin.linux noao binaries (NB) bin.linuz compressed core binaries (.z86) noao.bin.linuz compressed noao binaries (.z86) extern where "" can be anything, e.g. "/u1/iraf" on the Linux/IRAF development system. Create a link "/iraf" pointing to the root-dir on your system. Some files in the installed system point to /iraf/iraf by default; you can change this but it isn't likely to be worth it. 3.3 CREATE THE IRAF ACCOUNT As root, create a new account "iraf" with /iraf/iraf/local as the login directory and /bin/csh as the login shell. You should not create the login directory or any login files at this point. This account will be used by the IRAF system manager to maintain IRAF. Users should execute IRAF from their own account separate from IRAF. 3.4 INSTALL THE DISTRIBUTION FILES The distribution files are compressed tar files. Assume we are installing the AS, IB, and NB files and that we have a link /iraf such that /iraf/iraf points to the iraf root. The distribution files are in the scratch directory /d0/iraf. Then to recreate the directory tree we would do the following: # Example: install AS, IB, NB from distribution mirror in /d0/iraf. % cd /iraf/iraf % cat /d0/iraf/as.lnux.gen/as.* | zcat | tar -xpf - % cd /iraf/irafbin/bin.linux % cat /d0/iraf/ib.lnux.x86/ib.* | zcat | tar -xpf - % cd /iraf/irafbin/noao.bin.linux % cat /d0/iraf/nb.lnux.x86/nb.* | zcat | tar -xpf - If SS is installed instead of AS substitute "ss" for "as" above. If the compressed executables are installed instead of the normal uncompressed ones substitute ".z86" for ".x86" above. If both are installed merely repeat the last four lines for the second architecture, using .x86 for .linux and .z86 for .linuz. The IRAF files should be owned by the IRAF account. If you did not install the distribution as IRAF, you can do a "chown -R iraf ." (as root) at the IRAF root-dir to set the ownership to IRAF. 3.5 RUN THE INSTALL SCRIPT "su" to root and run the install script as follows: # cd /iraf/iraf/unix/hlib # ./install This will create a link /usr/include/iraf.h, add a couple FIFOs to /dev, and create links for the major IRAF executables in /usr/local/bin or wherever you choose. The install script will ask you for the default location to put user image pixel files, which should be some large scratch area (e.g. /d0/iraf on our test system). The install script can be rerun at any time to verify the installation or patch up anything that has gone wrong. 3.6 RUN IRAF Any user should now be able to do a "mkiraf" to set up their IRAF login directory, followed by "cl" to start an IRAF session. 3.7 CONFIGURE IRAF (OPTIONAL) Most sites will want to perform some site-specific configuration of IRAF, to interface local graphics devices or printers, interface magtape devices, set the default printer, modify the default list of packages loaded at login time, and so on. This is covered in detail in the Site Manager's Guide. Information on Linux specific issues is covered in this README. 3.8 REGISTER Don't forget to register! You can now do this conveniently online at http://iraf.noao.edu/register.html (just off the IRAF home page), or send in the registration form via email, ftp://iraf.noao.edu/iraf/REGISTER. 4. LINUX SPECIFIC ISSUES 4.1 WINDOW SYSTEM INTERFACE The IRAF system account (login directory ~iraf = /iraf/iraf/local) comes configured with a basic window system interface using the X11IRAF utilties xgterm and ximtool for graphics and imaging, and the Linux supplied fvwm for the window manager (plus a tin executable so you can remotely read the adass.iraf news from iraf.noao.edu - look in the root menu). If the IRAF account is configured as outlined above you should be able to login as "iraf" after installing IRAF, and if you are on the console the window system should fire up after a few seconds. The setup files provided can be used as examples for configuring user accounts. Compressed Linux binaries for xgterm and ximtool are included in the core distribution in ~iraf/bin. These are provided so that one can login to the "iraf" account and immediately use Linux/IRAF with a graphics interface after installing IRAF as outlined above. X11IRAF however is updated and distributed separately from the main IRAF system and you may want to check whether newer versions of these utilties are available and update them periodically. The IRAF archives on iraf.noao.edu contain the latest version of X11IRAF (currently in /pub/v2103-beta) as well as sources and binaries for other related utilties such as saoimage or xephem. More detailed information on xgterm and ximtool can be found in the Site Manager's Guide and in the ".info" files included with X11IRAF. 4.2 MAGTAPE INTERFACE Linux has a good but basic magtape interface for generic SCSI tape devices. This supports variable blocking by default and it should be possible to exchange tapes written on Linux systems with workstations and vice versa, assuming the tape drives are compatible models. The IRAF magtape interface is controlled by the dev$tapecap file. Linux/IRAF includes a version of this file tailored for Linux systems. Sample entries are included for DAT and Exabyte drives. Our development system has a HP35480A SCSI compression DAT drive which has been successfully used to exchange data with a similar drive on a Sun system. More detailed general information on configuring magtape devices can be found in the Site Manager's Guide. 4.3 SHARED LIBRARIES The IRAF system executables (CORE and NOAO executables and HSI executables) are statically linked non-Elf executables hence should be usable on any recent Linux system. 4.4 COMPRESSED EXECUTABLE OPTION The Linux/IRAF distribution does not yet include support for an IRAF shared library, which would reduce the size of executables and improve memory sharing. As an experiment however we are providing an optional IRAF architecture using GNU gzip/gzexe compressed executables. This can result in a significant disk space savings at some cost in runtime performance. Compressed executables are automatically and transparently uncompressed when executed. Compressed executables take about half the disk space of uncompressed executables, but start up slower as the file must be uncompressed before it can be executed. In the case of IRAF the start up penalty is not as great it might otherwise be due to the CL process cache. A disadvantage of compressed executables is that they require *more* memory to execute if multiple copies of the same executable are simultaneously executed, e.g. if there are multiple IRAF users or sessions, or background IRAF jobs, because no sharing of the text segment takes place. Linux/IRAF implements normal/compressed executables using the two architectures "linux" and "linuz", e.g. bin.linux or bin.linuz. You can choose to install either or both. If both architectures are installed you can experiment to determine which better suits your purposes, by setting the IRAFARCH environment variable before starting IRAF. For example, set IRAFARCH to "linuz" to enable the compressed executables. % setenv IRAFARCH linux # use normal executables % setenv IRAFARCH linuz # use compressed executables We recommend installing the normal uncompressed executables if you have lots of disk space, if IRAF will be used heavily on your system, or if multiple users will be using IRAF. The compressed executables may be preferable if disk space is tight or if IRAF is infrequently used. Variations on the default setup are possible. For example you could install the compressed executable (.z86, bin.linuz) and then manually uncompress the cl.e and x_system.e executables: % cd $iraf/bin.linuz % gzexe -d cl.e x_system.e This would provide most of the disk savings of compression, but fast startup time would be retained. 4.5 DISK REQUIREMENTS The following summarizes the disk requirements in megabytes for the major components of IRAF after installation (uncompress and untar). Component Size (Mb) Comment --------- ---------- ------------ AS 50.3 All sources SS 14.0 Stripped sources IB 20.3 normal CORE iraf binaries NB 21.9 normal NOAO package binaries IB-Z 10.7 compressed CORE binaries NB-Z 7.6 compressed NOAO binaries For example, the minimal possible install is SS + IB-Z + NB-Z which would require 32.3 Mb. A normal non-stripped install including sources is 92.5 Mb. A normal stripped install is 56.2 Mb. The maximal install is AS + all four binaries which would require 110.8 Mb. Mix and match as you choose. 4.6 OTHER IRAF SOFTWARE Actual IRAF installations usually include a number of external layered packages as well. Space for these is not included in this table since the external packages are not part of the main IRAF distribution (although they are indistinguishable from other IRAF packages once installed). Refer to the documentation for the layered packages you are interested in for information about the disk or other requirements for these packages. If you install many IRAF layered packages the disk requirements can run into the hundreds of megabytes. Examples of IRAF layered packages are TABLES, STSDAS, XRAY, EUV, FTOOLS, ICE, CTIO, NSO, GRASP, and so on. See http://iraf.noao.edu or ftp://iraf.noao.edu/contrib/ ftp://iraf.noao.edu/iraf/extern/ for pointers to some of these external packages. APPENDIX -- POST DISTRIBUTION NOTES --------------------------------------------------- Check this spot for notes added after the initial release. A1. RTAR -- Wed Sep 20 20:57:57 MST 1995 If you have segvios when running rtar, replace the executable (in $iraf/unix/bin.linux) by the version in this directory. This patch is for the original Linux/IRAF release ONLY. A2. ELF SUPPORT - Wed Jan 3 13:21:36 MST 1996 Newer Linux systems (e.g. Slackware 3.0) use ELF for objects, executables, and other binaries. The September 1995 Linux/IRAF release however was built using Slackware 2.3 which was an "a.out" system. The a.out format IRAF executables will run fine on ELF-based systems, but new programs cannot be linked as the IRAF libraries are a.out format, while newly compiled objects will be ELF format. The next Linux/IRAF release will support ELF directly. In the meantime the patch p-aout.tar.gz can be installed to workaround this problem. This patch was prepared on a Slackware 3.0 system but the ELF support in Slackware is pretty standard, so there is a good chance the patch will also work on other ELF-based versions of Linux. Before installing the patch make sure that your Linux installation includes support for a.out. On Slackware systems you must have installed the packages gccaout and libaout. If you did not do this when Linux was first installed you can do it later by loading the installation CDROM and running "setup" from within an xterm. Once the a.out support is installed the following directories should be present: /usr/i486-linuxaout /usr/lib/gcc-lib/i486-linuxaout To install the patch untar the patch file at the IRAF root: % cd $iraf % zcat p-aout.tar.gz | tar -xpvf - This will install a new version of XC (and a few other things) which supports a.out compilation on ELF systems. Finally you must patch Linux since the Linux a.out support omits the a.out version of libf2c.a, at least in Slackware 3.0. A copy of the old a.out libf2c.a is included in p-aout.tar.gz and after the patch is installed this file will be found in $hbin ($iraf/unix/bin.linux). Copy this file as follows: % cd $iraf/unix/bin.linux % su # cp libf2c.a /usr/i486-linuxaout/lib You should now be able to build IRAF programs (SPP, IMFORT, external packages) in the usual fashion. No extra command line switches are needed. This patch is for the original Linux/IRAF release ONLY and applies only to newer ELF-based Linux systems. A3. Patch 1 There was no patch-1 for Linux/IRAF. Linux/IRAF was released at the time of this patch hence it included the patch. A4. Patch 2 - Wed May 29 15:26:18 MST 1996 Patch 2 includes ELF support and is compatible with ELF versions of Linux (e.g. Slackware 3.0). The binaries are still all a.out format however, because we didn't want to make a major change to a new binary format in a patch. If you install patch-2 you do not need to install p-aout.tar.gz, since ELF support is already included in V2.10.4-p2 (you still need to install gccaout, libaout, and libf2c.a in Linux as noted in A2 above however). Patch-2 supplants all earlier patches. Patch-2 also includes a number of bug fixes and minor feature enhancements and is compatible with IRAF V2.10.4-p2 for other platforms. Case 1: You already have the V2.10.4 system installed and you want to install the patch. Unpack patch2.tar.Z at the iraf root and upgrade the BINs (install patch1 above first, excluding the BINs, if you have not yet done so): % cd $iraf % zcat patch2.tar.Z | tar -xpf - To upgrade the BINs download the new IB and NB distributions and reinstall the BINs as if you were installing for the first time. Patch 2 does not modify any site dependent files, other than the motd (to update the version information). You can install the patch file without concern that site dependent files such as the DEV files may be modified. Case 2: You are installing V2.10.4 from scratch. Just do a normal install as described in this README. All of the distribution files have been regenerated to include patch2. You can ignore the files patch2.tar.Z, p-aout.tar.gz, rtar.e.gz etc., these are used only to upgrade older installations. A5. F2CBIN patch - Tue Nov 19 10:51:56 MST 1996 The file f2cbin.tar.gz is a compressed tar file of the F2C Fortran-to-C translator used by Linux/IRAF. It has been reported to us that newer Slackware systems do not include f2c (they provide g77 instead). To install the patch, cd to / and untar the patch as root. This installs the F2C binary in /usr/bin and the library and include files in /usr/lib and /usr/include.