Building SymEngine
Installation
Install Prerequisites
- CMake v2.8.5 or above
- GMP 5.0 or above
- C++ compiler with C++11 features
How to obtain these using package managers are given below
Linux
Using gcc (Recommended)
Install prerequisites.
- g++ v4.7 or above
For Debian based systems (Ubuntu etc.):
apt-get install cmake libgmp-dev g++
For RPM based systems (Fedora etc.):
yum install cmake gmp-devel gcc-c++
To install do
cmake .
make
make install
Using clang
Install Prerequisites
- clang v3.4 or above
To install do
CC=clang CXX=clang++ cmake .
make
make install
OS X
With homebrew
With clang (Recommended)
- clang v3.4 or above
To install do
cmake .
make
make install
With gcc
Prerequisites
- g++ v4.8 or above
To install do
CC=gcc-4.8 CXX=g++-4.8 cmake .
make
make install
Windows
With MSVC
Prerequisites
- MSVC 14 2015
- MPIR. Rename mpir libraries to gmp accordingly.
To install do
cmake -G "Visual Studio 14 2015 Win64" -DCMAKE_PREFIX_PATH=/path/to/mpir/output/directory .
cmake --build . --config Release (or Debug)
cmake --build . --target install
For Win32 Platform
cmake -G "Visual Studio 14 2015" -DCMAKE_PREFIX_PATH=/path/to/mpir/output/directory .
With MinGW
Add mingw-get to PATH and then
mingw-get install mingw32-make
mingw-get install mingw32-gmp
To install do
cmake -G "MinGW Makefiles" -DCMAKE_PREFIX_PATH=C:\MinGW .
cmake --build .
cmake --build . --target install
With MinGW-w64
Compile gmp with MinGW-w64 and MSYS.
To install do
cmake -G "MinGW Makefiles" -DCMAKE_PREFIX_PATH=C:\MinGW .
cmake --build .
cmake --build . --target install