Crux Installation Instructions
This page will walk you through the steps of installing crux on your computer. It assumes you are working
in a command-line shell (readily available for Linux and Mac systems,
cygwin is the preferred choice for
Windows). The installation requires that you have gcc and make on your
computer.
All commands (words that you should type) are enclosed in
boxes. (Do not type the leading $, it indicates the
prompt). These instructions will refer to your home directory as
$HOME. You can type $HOME in the commands
or you can use the fully qualified path to your home directory which
may be something like /home/yourname/.
pwd or echo
$HOME
Installation
- Download the files Crux is freely
available for download under an academic use license. Once you have
submitted a license request, you will be sent a web address and login
information. On the download page you will be offered two types of files.
One is a set of compiled binaries (programs that are ready to run) and
documentation zipped together and the other is a tarball containing
the source code and documentation. If you are working on a Linux i686
or x86_64 system, the compiled binaries offer the easiest installation option.
Click on the link "Linux [architecture] Build (zipped)" to download
them to your computer. If a window pops up, select the "Save" button.
If you are on any other system or if the binaries do not work on your
computer, you will need to download the source files. Click on the
link "Source (tarred, gzipped)", again choosing to save to disk if
prompted. To check that the files were transfered correctly, run this
command
and compare the output to the "MD5 checksum" link next to the file you downloaded.
$ md5sum [downloaded file] - Unpack the files
- Option 1: pre-compiled binaries. The file you downloaded
should be named something like
crux_1.0x-i686-GNU-Linux.zip. Move it
to a convenient location and unpack the file with this command.
You should now have a new directory, bdist, with two subdirectories bin, and doc. The crux programs are in the bin directory. You may want to move these files somewhere more convenient for you, but otherwise, that completes the installation! Skip ahead to Changing $PATH for notes on how to run the executables.
$ unzip crux_1.0x-i686-GNU-Linux.zip - Option 2: source files. The file you downloaded should be named something like crux_1.0x.tar.gz, where 1.0x is replaced with the most current release version, such as 1.01. Move it to a convenient location and unpack the file with this command.
You should now have a new directory, bdist, with two subdirectories bin, and doc. The crux programs are in the bin directory. You may want to move these files somewhere more convenient for you, but otherwise, that completes the installation! Skip ahead to Changing $PATH for notes on how to run the executables. A new directory named crux_1.0x will be created and a long list of files will stream by as they are being put into the new directory.$ tar -zxvf crux_1.0x.tar.gz - Option 1: pre-compiled binaries. The file you downloaded
should be named something like
crux_1.0x-i686-GNU-Linux.zip. Move it
to a convenient location and unpack the file with this command.
- Configure Move into the crux_1.0x
directory from step 1 and confirm that there is a file called configure. This is a script you will run with one
additional pieces of information,
the location where you wish to install the crux
programs, lets call it
install-dir. If you want crux to go in $HOME/bin, theninstall-dirwould be $HOME. Configure will automatically put the programs in a directory called bin. Run one of these two commands.Crux defaults to single precision floating point arithmetic. It can be configured to use double precision floating point by specifying the$ ./configure --prefix install-dir--enable-doublesconfigure option.$ ./configure --prefix install-dir --enable-doubles
NOTE:configurewill not accept relative paths, such as ../../install-dir. Use fully qualified paths beginning with /. - Make To complete the process, run these two commands.
$ make
$ make install
Changing $PATH
You can always run any of the programs by specifying its full path. For example,
$ install-dir/bin/crux search-for-matches
In this final step of the installation, we'll set things up so that you can also run any of the programs by just typing its name. This is done with an environment variable called $PATH. $PATH is a list of places that the computer looks for executable programs. Find out what is in the current list with this command.
$ echo $PATHThe value returned might look something like this
/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games
The first directory in this colon-separated list, /usr/local/bin, is the first place the computer looks for a program. If it doesn't find the program there it tries /usr/bin and so on down the list. You can either move the crux executable files into one of these directories already in your PATH, or you can add install-dir to PATH with this command. (Remember to replace the word install-dir with the actual location of your installation)
$ export PATH=$PATH:install-dir/bin
Try 'echo $PATH' again to see that the change was made. install-dir/bin should be at the end of the list. Now you can run the crux programs by just typing their names. Try this.
$ crux search-for-matches
The change to $PATH is only temporary. As soon as you close the window, the change will disappear. In order to make the change every time you log on, add the line export PATH=$PATH:install-dir to the file .bashrc located in your home directory. You will have to log on again for the change to take effect.