swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Swarm on Linux


From: Pietro Terna
Subject: Swarm on Linux
Date: Mon, 07 Oct 1996 14:25:01 +0100

I am now running Swarm on Linux (I refer to 960513 release) and I report 
here my installation story. In my work I have been aided by many unknown 
friends and I hope now to help other 'installator'. Special thanks to Seth
McGinnis.

I'm no sure that all the steps that I will report here are necessary,
but the whole set works! To check if some step is truly unnecessary I
should have to repeat the installation omitting some step, or group of
steps, with a combinatorial effect, that I prefer to avoid.
Steps are not reported as effectively done, following the time, but ex post
rationalized. However, this is the order of the last installation
attempt (the successful one).

Yours, Pietro (Linux novice)

----------------------------

My Linux box: Pentium 90; Slackware 3.0; Kernel 1.2.13; GCC 2.7.2 (now)

----------------------------
Step 1
GCC 2.7.2 (I had 2.7.0). After an attempt on installing GCC 2.7.2 from the
source archive, with some problem of choice during the process, I decided
of downloading the executable

gcc-2.7.2.bin.tar.gz

from

ftp://sunsite.unc.edu/pub/Linux/GCC/

I downloaded also the related libraries

libg++-2.7.1.4.bin.tar.gz
(suggested in the README file of libg++-2.7.2.tar.gz, the source archive)

libc-5.2.18.bin.tar.gz
(probably also libc-5.3.12.bin.tar.gz works fine, but I have no experience
on it)

These three bin archives can be unzipped and untarred from /

The process seems to change also the symbolic links, but my suggestion
is that of looking to the following links, to check if they are directed
to the new files and libraries:

Installing gcc 2.7.2
    /usr/lib/cpp ->  ../lib/gcc-lib/i486-linux/2.7.2/cpp
    /lib/cpp     -> usr/lib/gcc-lib/i486-linun/2.7.2/cpp
        the second link is not automatically corrected,
        but I don't know the importance of it

Installing libc 5.2.18
    /usr/lib/libc.so -> libc.so.5.2.18
    /usr/lib/libm.so -> libm.so.5.0.5

Installing libg++ 2.7.1.4
    /usr/lib/libg++.so -> libg++.so.27.1.4
    /usr/lib/libstdc++.so -> libstdc++.so.27.1.4

----
Step 2
I have checked GNU make, verifying that I have v.3.74, which is the
version suggested in swarm installation notes

----
Step 3

libXpm

In the README file of xpm-3.4h.tar.gz, downloaded following the swarm site
link, I read the suggestion, for Linux installations, of using directly
the bin file
libXpm.3.4f-ELF.tar.gz downloaded from sunsite.unc.edu/pub/linux
Then I have unzipped and untarred it in /
All symbolic links seem to be automatically changed.

----
Step 4
tk4.0 e tcl7.4

I work as root with a temporary copy of the sources in
/root/temp/tcl
and /root/temp/tk

After applying, with (gunzip -c nome-patch.gz | patch -p), the patches
downloaded following swarm site links to the sources copied from slackware
CD ROM (dir /cdrom/linux/slakware/source/tcl/tcl+tk/ in my case),
I install:

tcl, by

./configure
make
make install

following f) in the README file, I build symbolic links, with 'ln -sf',
from tclsh to tclsh7.4 (in /usr/bin), and from libtcl.a to libtcl7.4.a (in 
/usr/lib).

tk, by

./configure
make
make install

following g) in the README file, I build symbolic links, with 'ln -sf',
from wish4.0 to wish (in /usr/bin) and from libtk4.0.a to libtk.a
(in /usr/lib). Beside this, the README file also suggests of building a
symbolic link to the tk library; in my case, a symbolic link from tk to
tk4.0 in /usr/lib just exists. (The same, for tcl and tcl7.4).

Running make test (under X Window), in each of the two directories I
obtain few errors, but (almost apparently) without consequences.

(I deleted the temporary installation of the source files in /root/provv)

----
Step 5
BLT-2.1

Using BLT2.1.tar.gz downloaded from Santa Fe site, I unzip and untar it in
/root/provv

Following README I use

./configure -with-cc=gcc

  (may be, it would be better to use
  ./configure -with-cc=gcc -prefix=/usr
  to avoid the use of /lib /bin /include /man in /usr/local/blt -- the
  default-- that forced me to copy the content of
  /usr/local/blt/lib in
  /usr/lib to run the 'make' command of the applications)

make
    don't run
    from the distribution list address@hidden
    I read the suggestion of looking at
    http://www.ai.uga.edu/students/jae/ai.html
    where one can read, about Swarm under Linux:
'It requires Tcl7.4/Tk4.0, libtclobjc and BLT 2.1 (both available at the
 swarm site). BLT2.1 requires one small fix to compile on linux.
 Modify the top level Makefile to make sure it points at the right
 tcl/tk files:
 STD_LIBS = -ltk -ltcl -L/usr/X11R6/lib -lX11

 This is with RedHat 3.0.3
 (should be the same for slackware or just about any other distribution).'

    (thanks to John A. Eikenberry)

correcting in this way the Makefile generated by ./configure

make
    runs perfectly

now, from X Window, running ./graph from demo dir, I verify that
anything goes well

finally
make install
    (I deleted the temporary installation of the source files
     in /root/provv)

----
Step 6
libtclobjc

Using libtclobjc-1.1b3 downloaded from Santa Fe site, I unzip and untar it in
/root/provv

 In his message of August 9, 1996, Thor Sigvaldason
<address@hidden>
 (thanks to Thor) wrote:
        '....  a small technical note. Line 1359 of the libtclobjc configure
 file (downloaded from SFI) reads:
     elif test -r $dir/libk.a; then

        What it's actually looking for are tk libs (ie. not klibs),
 so the line _should_ read:
    elif test -r $dir/libtk.a; then
                         ^
         This is not a major problem, as the library can be made
 without tk support. I have no idea what difference it makes, but if
 it's in the configure there must be some advantage.'

I reported the correction.

Then, following INSTALL file

./configure --with-readline
make
make check         (being in X Window)
make install

[I don't know if the inclusion of readline is essential; in my Linux
 installation readline.a was not present (I obtained it from Seth) and
 I have copied it in /usr/lib;
 I obtained readline.h from the source of gdb-4.14 in
 /cdrom/linux/slakware/source (in my case) and I copied it in /usr/include]

----
Step 7
Swarm

I unzip and untar swarm-960513.tar.gz in /home/terna/swarm (terna is
my last name), obtaining /home/terna/swarm/swarm
Then, following README file

--

In that directory, I modify Makefile.conf writing the following lines,
on the basis of Seth McGinnis example (newly, thank to Seth)

 OTHERINCDIRS=-I/usr/include/tcl
 OTHERLIBDIRS=-L/usr/X11R6/lib -L/usr/local/blt/lib
 OTHERLIBS=-lreadline -ltermcap -lieee

Some considerations:
(i)   -L/usr/local/blt/lib
      would be not necessary (and in Seth examples it is not present)
      if I had added -prefix=/usr making BLT, as noted before
(ii)  I don't know if -readline -ltermcap -lieee
      are all strictly necessary; if you want, you can try to
      eliminate one or more of them ...
      For examples, read the following message of May 3, 1996, from
      Nelson Minar <address@hidden>
'When I start any Objective C program on my Linux machine, I get a
 floating point exception.
      This is a bizarre bug in Linux libc-5.0.9. The quick fix is to
      hide the problem by linking all Objective C programs with -lieee
      (in Swarm, set OTHERLIBS in Makefile.conf to -lieee).
      Alternatively, upgrade to libc-5.2.18 or newer.'

--

Finally, I have corrected, in
/home/terna/swarm/swarm/src/simtools,
the file MessageProbeWidget.m, following May 22 1996
message of Manor Askenazy
***************************************************************************
--- BUG FIX --- BUG FIX --- BUG FIX --- BUG FIX --- BUG FIX ---BUG FIX ---
***************************************************************************

Please replace lines 99-101 of
swarm/src/simtools/MessageProbeWidget:

  objWindows = (int *) malloc(sizeof(int)*argNum) ;
  argNum *= 2 ;
  myWidgets = (Widget **) malloc(sizeof(Widget *)*argNum) ;

With:

  if(argNum)
    objWindows = (int *) malloc(sizeof(int)*argNum) ;

  argNum *= 2 ;

  if(argNum)
    myWidgets = (Widget **) malloc(sizeof(Widget *)*argNum) ;
  else
    myWidgets = (Widget **) malloc(sizeof(Widget *)) ;

--

Finally, finally, I have copied the content of /usr/local/blt/lib
in /usr/lib. Then in /usr/lib I have added
        ln -sf libBLT.so.2 libBLT.so.2.1
as was in /usr/local/blt/lib

(but this is a problem following the missing option -prefix=/usr
in BLT making)

--

Now, from /home/terna/swarm/swarm

make clean
make

and, after unzipping and untarring applications
(swarmapps-960513.tar.gz) in /home/terna/swarm

make clean
make

----
Step 8
... enjoy

from X Window, enter an application dir, e.g.
/home/terna/swarm/heatbugs (in my case) and run the executable file
(e.g. heatbugs)

----
Step 9
The end

----
Step 10
PS
(i) I have to apply the suggestion of Post-compile cleanup
section in install.html of swarmdocs-960513.tar.gz

(ii) I newly need help: with GCC 2.7.2 installed, make zImage -
in kernel compilation process - fails.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]