Unix
The preferred way to install Bsoft 2 is through already compiled binary distributions for Linux or Mac OS X. Note that the current Mac OSX systems require an updated Tcl/Tk (see below). For other Unix flavors, the source code needs to be compiled.
Note: There is a bug on Ubuntu that prevents proper compilation and launching of shared objects. I would advise compiling Bsoft on Fedora or a related Redhat distribution. It should run under Ubuntu as well.
Platforms supported
Bsoft 2 should compile on any of the following platforms, potentially with some tweaks in the compiler scripts:
- Linux (i386/i686, x86_64, PowerPC, Alpha, Itanium)
- Darwin or MacOSX (PowerPC, Intel, ARM64)
- IRIX64 (SGI)
- Solaris (Sun)
- AIX (IBM)
- OSF1 or Tru64 (Alpha)
- VMS (Alpha)
- Cygwin_NT (Windows NT)
Requirements
Mac OS X:
The default installations of Mac OS X don't have the compilers installed. Download Xcode from the Apple developer's web site and install it first:
Note that the Mac OS X Xcode versions should be matched with the different operating systems:
- Mac OS X 10.4 (Tiger): Xcode 2.5
- Mac OS X 10.5 (Leopard): Xcode 3
- Mac OS X 10.6 (Snow Leopard): Xcode 3
- Mac OS X 10.7 (Lion): Xcode 4
- Mac OS X 10.8 (Mountain Lion): Xcode 4
- Mac OS X 10.9 (Mavericks): Xcode 5
- Mac OS X 10.10 (Yosemite): Xcode 6
- Mac OS X 10.11 (El Capitan): Xcode 7
- Mac OS X 10.12 (Sierra): Xcode 8
- Mac OS X 10.13 (High Sierra): Xcode 9
- Mac OS X 10.15 (Catalina): Xcode 12
- Mac OS X 11 (Big Sur): Xcode 13
- Mac OS X 12 (Monterey): Xcode 14
- Mac OS X 13 (Ventura): Xcode 14
The Z library:
The inclusion of the PNG format in Bsoft requires libz for compression. The required files are:
- /usr/include/zlib.h or /usr/local/include/zlib.h
- /usr/lib/libz.* (such as libz.a or libz.so)
Tcl/Tk:
Bsoft is primarily a command-line package, with all the necessary code included in the package. However, from version 0.9, it includes a Tcl/Tk interface and a Tcl/Tk script, bshow, useful for the display of images and a few interactive manipulations (not available for VMS). The Tcl/Tk version must be 8.3 or higher. Bsoft can be compiled without Tcl/Tk (see below for details).
On most Unix boxes, the Tcl/Tk headers and libraries are installed in either /usr or /usr/local (look for /usr/include/tk.h or /usr/local/include/tk.h). Linux distributions typically have separate packages for the runtime and developer versions of Tcl/Tk. Both need to be installed to be able to use bshow.
The Bsoft compiler script, bmake, tries to find the Tcl/Tk headers automatically. Make sure the Tcl/Tk version is 8.3 or higher. There may be a version suitable for installation under VMS, but try at your own risk. Make sure the commands "tcl" and "wish" are in your executable path.
Mac OSX:
The version of system Tcl/Tk for Mac OSX is stuck at 8.5.9, which does not work any more. Download the Tcl/Tk 8.6 version from https://www.tcl.tk/software/tcltk/download.html (Both tcl and tk). Unpack the distributions. Change to the macosx subdirectory in each and run the following commands (tcl first):
./configure make sudo make installThis should install the frameworks as /Library/Frameworks/Tcl.framework and /Library/Frameworks/Tk.framework, and set up the links to the version 8.6 tclsh and wish executables. Check the version with:
echo 'puts $tk_version; exit' | wish
Fedora:
sudo yum install tk-devel
Ubuntu:
sudo apt-get install tk-dev
XML:
The default format for parameter files is the STAR format. These can also be written in an XML format, but requires the libxml2 library with its header files. The common locations for the header files are in /usr/include/libxml2 and the library in /usr/lib. The source code for this library is not included in Bsoft due to its sheer size.
Fedora:
sudo yum install libxml2-devel
Ubuntu:
sudo apt-get install libxml2-dev
Required packages
These packages can be replaced with newer versions. This will require recompiling everything
FFTW3
Web site: FFTW
TIFF library
Web site: http://www.remotesensing.org/libtiff
JPEG library
Web site: http://www.ijg.org
PNG library
Web site: http://www.libpng.org
Download
Unpack
tar xzvf bsoft2_1_3.tgz
Compile
bconf -c make make install BINSTALL=/usr/local/bsoft