1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267
|
See the Normaliz manual, doc/Normaliz.pdf, Chapter 11, for
installation prerequisites (compiler, build tools, and libraries) and
how to install them using the install scripts in the distribution. This
file contains additional information.
**********************
**** PACKAGES ****
**********************
For rational polyhedra:
CoCoALib, https://cocoa.dima.unige.it/cocoa/cocoalib, version 0.99818
MPFR, https://www.mpfr.org/, version 4.2.1
Flint, https://flintlib.org/, version 3.0.1
nauty, https://users.cecs.anu.edu.au/~bdm/nauty/, version 2_8_8
nauty should be configured with --enable-tls.
For SHA256 hashes:
hash-library, https://create.stephan-brumme.com/hash-library/, version 8
For algebraic polyhedra additionally:
MPFR and Flint as above
e-antic, https://github.com/flatsurf/e-antic, version 2.0.2
Note: arb and antic are now contained in Flint.
*********************
**** SCRIPTS ****
*********************
The Normaliz install scripts handle the installation without any user interaction.
They generate directories and files only within the Normaliz directory, unless
the user forces them to do otherwise.
The use of the install scripts is described in the Normaliz manual,
doc/Normaliz.pdf, Section 11.2.
In addition, the installation can be controlled by several environment variables:
NMZ_SHARED: if set, the Normaliz binary is linked dynamically
NMZ_COMPILER: overrides the standard choice of compiler (g++ on Linux, clang++ on Mac)
NMZ_PREFIX: if set defines the path for make install;
by default it is "local" in the Normaliz directory
GMP_INSTALLDIR: sets the path to the GMP files
NMZ_OPT_DIR: sets the directory to which the sources of the optional libraries are downloaded;
by default it is the subdirectory "nmz_opt_lib" in the Normaliz directory
NO_OPENMP: if set, blocks OpenMP in the compilation of Normaliz (and e-antic)
NMZ_EXTENDED_TESTS: if set, activates compilation for extended tests
EXTRA_FLAGS: One can further control the build process of Normaliz itself by setting options
for configure using this variable, the contents of which are appended to the call to the
configure script; see
./configure --help
Have a look at the install scripts.
************************
**** THE TEST SUITE ****
************************
Normaliz has a large test suite contained in test and its subdirectories. If Normaliz has been
built in build, one can simply navigate to this directory and type
make check
This will run all checks that fit the installed version of Normaliz.
The checks are based on Makefile.classic in test. A direct access is also possible. Within test
it is started by
make -f Makefile.classic [<goal>]
This call assumes that the binary normaliz is located in ../source (for historical reasons).
The binary can be defined by
make -f Makefile.classic <goal> NORMALIZ=path_to_normaliz/normaliz
The general method is to create an output file and to compare it to a reference file. Certain
tests create two output files per input file, for example integer hull computations or
automorphism groups.
Strict and non-strict tests
---------------------------
With STRICT=yes, the output files are compared to the reference files without any exception.
Otherwise some data will be skipped in the comparison, especially the floating point
approximations to algebraic numbers. For this purpose a test copy of the output file is made
which is then deleted after the (successful) test.
Check of terminal output
-------------------------
With OUTPUTCHECK=yes, no comparisons are made and this helps to detect any unwanted terminal output.
Basic tests
-----------
The default goal is all. It runs the tests that do not depend on an optional package. The goal
total runs the tests in total, including those depending on the optional packages (except testLARGE).
The tests depending on the existence of CoCoALib are covered by the goal testInt. Those requiring
nauty are called by testAut and the tests for algebraic polyhedra depend on several goals:
testnf testnfH testdegQ testnfAut
namely general tests, integer hull tests, tests of degenerate polytopes, and finally the computation
of automorphism groups, which requires nauty as well.
If diff finds differences, these are recorded in a file with suffix diff and printed to the terminal.
Thwe goal msys asks for all and testAut.
Extended tests
--------------
Since the tests must be fast, they cannot cover those parts of the program that aim at large computations
or are critical for arithmetic. Therefore it is possible to disguise small computations as being large.
This is done via cone properties
TestArithOverflowFullCone TestSmallPyramids
TestArithOverflowDualMode TestLargePyramids
TestArithOverflowDescent TestSimplexParallel
TestArithOverflowProjAndLift TestLinearAlgebraGMP
TestLibNormaliz
The names are self-explanatory, but sometimes they are also used for a purpose that is not evident
from the name (in order to avoid further cone properties). These cone properties are always defined,
but they are ignored, unless Normaliz has been compiled with NMZ_EXTENDED_TESTS.
(See install_normaliz.sh or source/Makefile.configuration.)
Large tests
-----------
It is possible to run truly large tests via the goal testLARGE. They are time consuming.
The goal testpatch runs tests for the patching algorithm. Takes some time as well.
********************
**** plain MAKE ****
********************
Under Linux and MSYS one can still use our old simple plain Makefile.
IT IS MEANT FOR THE DEVELOPMENT OF NORMALIZ under Linux and the MS Windows compilation
by MSYS (see below). It only compiles static binaries.
It is assumed that the optional libraries are installed in
local
within the Normaliz directory.
1) Go to the source directory
2) Check the configuration in Makefile.configuration, especially the locations of
the optional packages and their versions.
3) Say
make -f Makefile.classic -j<number of threads>
It should work without change of Makefile.classic or Makefile.configuration on many systems
that have a system installation of the needed libraries.
(We must use the name Makefile.classic since Makefile is occupied by autotools.)
If everything is successful, then the executable file normaliz is
in the source directory. You may of course want to move them somewhere else.
Makefile.classic accepts optional arguments (also simultaneously): for example,
make -f Makefile.classic NAKED=yes # deactivates all optional libraries
Similarly:
OPENMP=no # deactivates OpenMP
COCOA=no # deactivates CoCoALib
FLINT=no # deactivates Flint
EANTIC=no # deactivates e-antic
NAUTY=no # deactivates nauty
HASHLIBRARY=no # deactivates hash library
NMZ_DEVELOP=no # deactivates development version
NMZ_EXTENDED_TESTS=yes # activates extended tests
NMZ_DEBUG=yes # sets -g3 for compilation instead of -O3
You must make sure that everything is compiled with the same set of options!
In doubt use "make -f Makefile.classic clean" beforehand.
5) If you want to install Normaliz, Say
make -f Makefile.classic install
Installs Normaliz in "local" (including libnormaliz.a and the necessary header files).
6) Makefile.classic includes a target "clean". It will remove the compiled files
(but not uninstall them) by
make -f Makefile.classic clean
************************************
**** Compilation for MS Windows ****
************************************
--- The auxiliary packages have not yet been updated ---
UNDER CONSTRUCTION
Normaliz can be compiled for MS Windows under MSYS2/MinGW64 with all optional libraries.
Important restriction: only static build of normaliz.exe and libnormaliz.a possible at this time.
To this end you must install MSYS2 including the MinGW64 toolchain. Additionally the
cross-compiler package must be installed if you want to compile the packages written in C.
Add GMP and Boost (for e-antic). Make sure to choose the packages for MinGW64 when
running pacman
Log in under MYS2 MinGW64.
We recommend a separate directory for MSYS builds. Do not use Linux or MacOS
directories of Normaliz.
Download the Normaliz source as a tar.gz from GitHub and extract it as usual or get in an
equivalent way. (Later on, tinstall_normaliz.sh will copy version.h and nmz_config.h
into source/libnormaliz.)
WARNING: The installation is extremely delicate in its use of static and shared
libraries. Therefore do not tamper with PREFIX.
Optional packeges that must be preinstalled:
1) Download MPFR_for_msys.zip from https://github.com/Normaliz/Normaliz/releases/tag/v3.9.2.
Unzip and run pacman -U on the zst files.
2) Install Flint from the MSYS repository via pacman -Ss (for finding the best version) and
install via pacman -S.
The next step will additionally install static libraries of MPFR and Flint. They are
necessary for a normaliz.exe that depends only on system DLLs.
IMPORTANT: Make sure that install_scripts/opt/header_files_for_Makefile.classic contains
the right version of version.h.
Then we navigate to the Normaliz directory and run ./install_normaliz_with_eantic.sh.
This will install CoCoA, nauty, hash-library, arb, antic and e-antic, as well as
static versions of MPFR and Flint. During the installation of e-antic, the files
libflint.a and libmpfr.la are hidden in the subdirectory hide of local/lib. Should
the installation of e-antic crash, copy them back manually.
Moreover, the script runs Makefile.classic for making and installing static libnormaliz.a
and normaliz.exe. (Unfortunately, autotools builds of normaliz.exe do not produce
a working normaliz.exe.)
Except for CoCoA we use the official releases. For CoCoA we download a pre-release version
of CoCoALib-0.99710 rom https://github.com/Normaliz/Normaliz/releases/tag/v3.9.2
that is then patched by the files in install_scripts/cocoa_patches.
(configure has been modified by adding -fpermissive and -Wconversion to CXXFLAGS.)
Note: if you don't have (or want) all optional packages, edit source/Makefile.configuration
to disable the missing/unwanted ones, and edit nmz_config.h accordingly.
After successful compilation you will find normaliz.exe in source and the Normaliz
directory. libnormaliz is installed in local.
If ecerything has worked out, normaliz.exe depends on Windows system DLLs.
Tests: do not use STRICT=yes since the 32bit arithmetic creates problems for floating point.
|