Thread: installing 05Jun07 distribution on 64 bit linux

Started: 2007-03-10 00:30:00
Last activity: 2007-03-10 00:30:00
Topics: SAC Help
Renate Hartog
2007-03-10 00:30:00
Thought I'd share my experience installing this version of the source code
on my 64-bit Red Hat Linux system;

from Changes file:
2005/05/26 Brian Savage <savage13<at>dtm.ciw.edu>
* Fully integrated libedit into build process -> turned out to be
a little tricky on 64-bit if you want to compile it with -m32
* Updated Readme, License, History, Readme.buildsac files
* Removed extra CC=cc lines in makefile
* Updated Makefile for better install process

These are the problems I ran into with fixes:

-can't find X11 library: fixed by adding a soft link called libX11.so in
/usr/X11R6/lib to the libX11.so.6.2 file that was in there (a 32-bit
library).

-to compile for 32bit rather than 64 bit: Added the following lines to the
sac/src/makefile:
ifeq ($(MACHTYPE),x86_64)
DEFINES += -m32
endif

This compiled all the SAC-source code with the flag -m32

-ld can't find crt1.o -> fixed by installing glibc-devel.i386 which put
the needed file in /usr/lib

-sac compiled, but died with segmentation fault -> turns out there still
were some 64bit libraries: libedit did not get compiled with the -m32
flag, the sac-distribution actually installs this library from scratch
from a tar-file. I edited sac/libedit/libedit-2.6.9/Makefile.in and added
-m32 to all the $(CC) calls that did NOT use CFLAGS, and I set an
environment variable CFLAGS to -m32. Then I made a NEW tar-file
libedit-2.6.9.tar.gz (after copying the original just in case).

-cd'd back to sac/src, did make clean to remove any old 64-bit stuff, then
did make and it now seems to be working.

Thanks to all who respond to this email list because I wouldn't have been
able to figure it out so quickly without your previous experience
compiling on 64-bit!

-Renate
---------------
Renate Hartog
PNSN/UW Seismology Lab

09:36:03 v.01697673