                      Mathomatic Installation Instructions
                      ------------------------------------

The requirements for easy installation from this source code are: the GNU
make utility and the GNU C compiler (gcc).  Other C compilers may be used,
but may require small changes to the makefile and source files.  You will
need to open a shell window to compile and run Mathomatic.

Under Mac OS X, the required compilation software is included in Xcode Tools,
which is available on one of your Mac OS X installation discs or downloadable
from the Apple developer tools website.  To open a shell window, double click
on the Terminal application in Applications/Utilities.

On a Debian or Ubuntu Linux computer, the "build-essential" and readline
development packages are required to compile Mathomatic with readline
functionality.  To open a shell window in desktop Linux, launch
Applications/Accessories/Terminal.  To skip these compilation instructions
and install Mathomatic, already compiled and ready to run under Debian or
Ubuntu, type:

	sudo apt-get install mathomatic

at the shell prompt, then type your password if prompted for it.  You can
then run Mathomatic by typing "mathomatic".  This is possible because
Mathomatic is an official Debian package.

The Mathomatic code is portable, self-testing, and easily compiles and
installs using GNU utilities under BSD Unix, Solaris, Linux, Mac OS X, and
under the Cygwin environment for Microsoft Windows.  Precompiled, ready to
run, binary packages may be available from your operating system's package
manager or from the Mathomatic website: www.mathomatic.org

Root (super-user) or administrator permission is needed to install
Mathomatic, because write permission is needed to copy files into the
directories in "/usr/local".  Mathomatic need not be installed to run the
compiled executable.

A typical compile/install is done by typing the following at the shell
prompt, while in the Mathomatic source code directory:

	make READLINE=1
	make test
	sudo make install

That will compile the source code with readline enabled, test the
functionality of the generated executable (named "mathomatic"), and install
the executable, docs, and tests in "/usr/local" in less than a minute.  After
that, typing "man mathomatic" should bring up the man page, and typing
"mathomatic" should run Mathomatic.  If Mathomatic doesn't run, check that
the PATH environment variable includes "/usr/local/bin" with the shell
command "echo $PATH".

To install in "/usr" instead of "/usr/local", type:

	sudo make prefix=/usr install

sudo asks you for your password; if it doesn't work, login as root or type:

	su -c "make install"

and enter the root password to install as the super-user.

To compile and install under Solaris with gcc:

	make READLINE=1
	su root
	prefix=/usr  docdir=/opt  INSTALL=ginstall  make install
	exit

To install everything, including m4 Mathomatic, which allows easy entry of
math functions like sqrt(x) and sin(x) as macros, use "make m4install"
instead of "make install".

To undo the installation, removing Mathomatic from the local computer, type:

	sudo make uninstall

These instructions were written by George Gesslein II of www.mathomatic.org
