Unless you are using a Windows or a Unix system with pre-built package manager support (Debian GNU/Linux 2.2, Redhat 6.1, Solaris 2.7), installing Swarm will take some time: various external libraries need to be acquired, compiled, and installed, and then Swarm itself needs to be compiled. Please report any problems during installation back so that we can try to fix them in the future. If you are using a Unix system with binary package manager support, please read the manual appropriate to the manager. Respectively, these are `dpkg', `rpm', and `pkgadd'. Swarm uses quite a few libraries and is intended to run under all major flavors of Unix. This presents the unpleasant but largely unavoidable side-effect of making Swarm hard to install. Ideally, you should get the sys-admin for your site to do the job. In any event, the new online Swarm FAQ where we've tried to compile some of the common obstacles to installation, may be useful.
|
Unix. Our intention is that Swarm will run on any modern Unix system. Ideally, Swarm itself should be 100% portable. Swarm has been known to run on SunOS 4.1.3, Solaris 2.[567], GNU/Linux systems for Intel, Sparc, and PPC, FreeBSD, HPUX 9, 10, and 11, IRIX 5.3 & 6.5, Digital Unix for Alpha and MachTen/68k.
Windows NT. Swarm can be used on Windows. Installation on Windows is a simple matter of running the InstallShield package. Please see the release page, for more details.
See the Platform News web page for the most up-to-date information.
We assume you already have Unix and X Windows on your system: the rest of this software is freely available. Expect to spend some time compiling and installing these packages. URLs on this page are to the home distribution site: as a convenience, the Swarm ftp site contains copies of the necessary packages in needed-software.
GNU gcc. gcc is the FSF's GNU Compiler Collection. You need gcc 2.95.2 or greater installed on your system, including the Objective C support. The latest version is available from ftp://ftp.gnu.org/pub/gnu/gcc.
GNU make. Make is used to automate building programs: every OS ships their own version of make with some random set of features. The Swarm makefiles currently use features that are not supported by all makes: GNU make is the only one guaranteed to work. Linux systems probably use GNU make already. The latest version of GNU make is available here.
GNU gdb. gdb is the GNU debugger: Swarm doesn't require this, but you will probably want gdb on your system to debug programs. gdb is available here.
GNU Emacs. Emacs is a programmable text processing system and editor. Emacs is needed if you want to build Swarm for Java from source code. Emacs is also a good program for editing Objective C and Java code. Emacs is available here.
Swarm uses a variety of freely available software libraries. All of these libraries need to be configured and installed independently of Swarm. When you configure Swarm itself, take a look at the output of "configure --help" to see what "--with-*dir" options are available for locating the installations of these libraries.
XPM Library. The XPM library adds pixmap (coloured bitmap) support to X11. XPM is a common X library, many systems already have it installed. A reasonably modern version is needed: we've used version 3.4f. If you get complaints about "Object" being multiply defined, your version of libXpm is too old. The library is available from ftp://ftp.x.org/contrib/libraries/xpm-3.4k.tar.gz.
ffcall / libffi. Either ffcall or libffi can be used in Swarm to provide the underlying support for message probing. ffcall is provided with Swarm and works for most platforms. Both libraries provide a portable, high level programming interface to various platform calling conventions. This allows a programmer to call any function specified by a call interface description at run time. ffi stands for Foreign Function Interface. A foreign function interface is the popular name for the interface that allows code written in one language to call code written in another language.
The latest version of ffcall is 1.6
The latest version of libffi is: 1.20
libpng. Swarm requires support for pixmap images - `png' provides that support.
The current version is 1.0.5
zlib. png requires data compression which zlib, a general data compression library, provides.
The current version is 1.1.3.
Once you have all of the above software installed, the next step is to configure Swarm. First unpack the Swarm .tar.gz file into a convenient place (via gzip -dc swarm-xx.yy.zz.tar.gz | tar xf -).
As of the Swarm 1.2 release, the compilation and installation of Swarm is handled by a GNU configure script. This removes a large burden from the user, as configure has some intelligence which automatically sets many common options.
You first need to read the file INSTALL with the release of Swarm, in the top-level source directory, to determine the appropriate and recent options to give to the configure script (this is analogous to what you needed to do when editing the *INCDIR macros in the obsolete Makefile.conf in earlier releases).
You've done the hard part, now type make, as in earlier releases from the top of the source directory, and watch the fun! If running make in the root Swarm directory does nothing, you probably aren't running GNU Make.
There is now an explicit "installation" step to install Swarm -- make install so that binaries and libraries can be installed cleanly to a specified location. On many Unix systems this likely to somewhere like /usr/local/.
The Makefiles included by user-created libraries, and user-created applications are Makefile.lib, and Makefile.appl, respectively. These distributed with earlier versions are now generated by configure . If you run into problems, the right thing to do is to re-run configure, and re-install Swarm, tinkering with these generated Makefiles directly is not recommended.
Swarm applications are distributed separately: you will need to download and unpack applications independently. After the application is unpacked, you will have to set the SWARMHOME environment variable to where you installed Swarm. All you need to do now, to compile an application is type make.
Once the application is compiled, just run it out of its own directory. A control panel and a couple of parameter windows should pop up; press the "Go" button to watch it run. Congratulations!
After you've tried out the Swarm libraries for awhile you may want to clean up the intermediate .o files, and other generated files, in the original source directory. Once you have done the make install you can remove the entire source directory, or if you might want to re-install later with different option, just type make clean to clean-up all files generated by the original make. See your the file INSTALL in the Swarm distribution, for more details.
Just remember to set $(SWARMHOME) to the right directory in your application's makefile. If you have installed Swarm, but for some reason, need to recompile the library and want to start from a completely clean source directory, you can run make uninstall and then make clean- see INSTALL file again here.