Skip to content

Commit

Permalink
update instructions for building flint
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrik-johansson committed Jun 27, 2023
1 parent 9d3116a commit af141d7
Show file tree
Hide file tree
Showing 3 changed files with 179 additions and 270 deletions.
51 changes: 21 additions & 30 deletions INSTALL
Original file line number Diff line number Diff line change
@@ -1,50 +1,41 @@
Instructions on installing FLINT
----------------------------------

If you obtained a tarball of FLINT, you should be able to install FLINT through
the following standard format:
Building FLINT requires:

./configure
make
* GMP (https://gmplib.org/)
* MPFR (https://mpfr.org/)
* Either of the following build systems:
* GNU Make together with GNU Autotools
* CMake

On a typical Linux or Unix-like system where Autotools is available,
FLINT can be built and installed as follows:

.. code-block:: bash

./bootstrap.sh
./configure --disable-static
make -j
make install

We also recommend that you run `make check' before installing. However, this
assumes that GMP and MPFR are already installed in the default search path of
your compiler (e.g. /usr/include/ and /usr/lib/). If these libraries are not in
such location you must specify where they are by passing their location to
configure `--with-gmp=ABSOLUTE_PATH` for GMP and `--with-mpfr=ABSOLUTE_PATH`
for MPFR. You can also change other settings. For a complete list, write
We also recommend that you run ``make check`` before installing.

./configure --help
For a complete list of build settings, write

The configure script also assumes you wish to install FLINT at the prefix
/usr/local. If you wish to install the library to another location, you must
pass the path to the location via `--prefix=PATH'.
./configure --help

An example of a custom configuration command would be

./configure \
--enable-assert \
--enable-avx2 \
--disable-static \
--with-gmp-include=/home/user1/builds/includes/ \
--with-gmp-lib=/home/user1/builds/lib/ \
--with-mpfr=/usr \
--prefix=/home/user1/installations/ \
CC=clang \
CFLAGS="-Wall -O3 -march=alderlake"

As mentioned, you can see the full list of options by running

./configure --help

However, if you only obtained FLINT directly from source, `configure' should be
missing. To generate the `configure' file, you also have to run

./bootstrap.sh

This assumes that you have `autoconf', `automake' and `libtool' installed. If
you have installed GMP or MPFR from source, then you should already have these
utilities.

Note that the FLINT building system can handle GMP and MPFR as installed at some
location and as source builds (built from source but not installed). Though, to
run the FLINT tests, GMP and MPFR needs to be properly installed.
For more information, see the FLINT documentation.
Loading

0 comments on commit af141d7

Please sign in to comment.