Compiling Mathemagix from its sources
Home | Download | Language | Packages | Develop | Contact | Jobs | Search

1.Checking dependencies

For a minimal build of the Mathemagix interpreter, you will need to ensure that Libtool has been installed on your system with support for building dynamic libraries. In addition, you probably want to install Readline, which is convenient if you want to use the interpreter from a shell.

The other packages of Mathemagix each come with their specific dependencies; see the package list. The two most important dependencies are Gmp and Mpfr, which are required by almost all other packages. Developers may also want to install Autotools, Doxygen and TeXmacs.

2.Downloading from the svn server

The sources can be downloaded from the svn server located at http://gforge.inria.fr/projects/mmx/ via the following command:

 svn checkout svn://scm.gforge.inria.fr/svn/mmx

This will create a mmx directory containing all the source files. In the case that you wish to contribute, just ask for an account via the above gforge page.

3.Setting up the paths

Once the sources are downloaded, go into the mmx directory and setup the paths needed for the compilation.

cd /path/to/mmx
source set-devel-paths

Remark 1. Sourcing the script set-devel-paths will enable you to directly run Mathemagix after its compilation, without doing make install. Since Mathemagix consists of many packages, this behaviour is convenient for developers. Indeed, reinstalling a package after a modification may cause dependant packages to be recompiled over and over again.

4.Configuration

Mathemagix complies with the standard GNU installation procedure. In a text terminal or console, and within the mmx directory, type the following command:

./configure

The default list of the package to be handled is thus printed. The latter list can be customized thanks to the –enable-package options. Dependencies are treated automatically. For instance

./configure --enable-algebramix --enable-mmxlight

will build the package algebramix and the interpreter mmxlight, as well as all dependencies (in this case basix and numerix). Notice that extra packages can be enabled a posteriori, simply by redoing a ./configure; this will not recompile the packages which are already available.

To build Mathemagix on certain architectures, such as MacOS, you may need to specify additional include and library paths as follows:

./configure CPPFLAGS=-I/sw/include LDFLAGS=-L/sw/lib

To build it on Windows, you will first to install first MinGW and msys first. Then the configuration process is the same. The list of all options is obtained using

./configure --help

For more details on the configuration options, see here.

5.Compilation and running

In order to compile the sources now type

make

in your console. As a result the packages will be configured and compiled automatically in a suitable order. When done, and assuming that you sourced the set-devel-paths script, you should have the binary mmx-light in your path. The interpreter is launched using

mmx-light

Typing 1+1 at the prompt should produce the output 2.

6.Installation

At this point, all libraries and binaries are located inside the directory tree where you compiled Mathemagix and you can only use them after sourcing the set-devel-paths script. In order to cleanly install Mathemagix, type

make install

By default the software will be installed into /usr/local. If you want to install elsewhere, then use

./configure --prefix=mypath

during the configuration phase.

7.Documentation

In order to build the html documentation, setup –enable-doc within configure and type make html once the sources have been compiled. It is supposed that TeXmacs and Doxygen are installed on your platform.

The main documentation is located in the toplevel doc/ directory. Each package is then documented within its own doc/ directory, usually throughout the Doxygen software, and is produced via make html. Packages must have been configured with the –enable-doc option. Installation is made according to the datarootdir configuration setup via make.

8.Known problems

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License. If you don't have this file, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.