Before begin able to compile the textIR suite of applications, the system is required to have g++, gcc, bison and yacc. If your system is running Debian Linux, each of these are available in the Debian repositories.
The textIR suite can be built with or without dlsa. The singular value decomposition computed in dlsa requires the use of arpack++, which in turn depends on the libraries ARPACK, Super_LU and either LAPACK or BLAS and either g2c or gfortran. The textIR build system will check for the availability of these libraries when configured.
Note that if using a Debian based system, these libraries can be obtained by issuing the command sudo apt-get install libarpack2-dev liblapack-dev libsuperlu3-dev
textIR uses the GNU build system (autotools). Those that are familiar with the system can download the textIR package and install with ease. For those that are not familiar, the install process is outlined below.
The current version can be found here: textIR-0.5.tar.gz, having the md5 checksum 989808ec338c97bddfddc4681ab6e44a
.
Unpack the code by issuing the the command: tar -xvzf textIR-0.5.tar.gz
This will extract the contents into the current directory.
After the source has been unpacked, move into the textIR directory.
Configure the code by issuing the command ./configure
To enable the compilation of dlsa, issue the command ./configure --enable-arpack
instead.
By providing the --enable-arpack
option, the environment will be checked for the availability of ARPACK, Super_LU, LAPACK, BLAS and arpack++. If the libraries and header files are found, the configure script will exit normally and create the Makefile. If some the required libraries or header files are not available, an error will be reported and the problem must be fixed before the compilation can continue.
Note that most errors will be due to the paths to libraries and headers not being found. To set the path to each of the required libraries (libarpack.a, libsuperlu.a, libblas.a, liblapack.a) set the environment variable LDFLAGS. For example, if the user "foo" downloaded the source of the required libraries and compiled them in his home directory, he would set this variable using the command export LDFLAGS="-L/home/foo/ARPACK -L/home/foo/SuperLU_3.0
-L/home/foo/BLAS"
Note that we are assuming that "foo" is using the BASH shell. To set the path to the arpack++ headers, "foo" would issue the command export CPPFLAGS="-I/home/foo/arpack++/includes"
Once the paths have been set, configure
must be run again so it can find and test the libraries and header files.
If planning to install the textIR suite locally (e.g. in your home directory), provide the option --prefix=/pathtoinstall
to the configure script. For example, if "foo" wanted to install the textIR suite in the textIR directory within his home directory, and he wanted to compile dlsa, he would issue the command ./configure --prefix=/home/foo/textIR --enable-arpack
For more configure options issue the command ./configure --help
Build the programs by issuing the command make
To test the built application suite, issue the command make check
. A set of tests will be run to identify whether the application were built correctly, and the results of the test will be displayed.
Finally, install the set of programs by issuing the command make install
The set of applications will be installed system wide, unless the --prefix
option was given during the configure stage.