-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathautoconfig_gmp_mpfr_mpc.sh
executable file
·44 lines (43 loc) · 1.53 KB
/
autoconfig_gmp_mpfr_mpc.sh
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
#!/bin/sh
# Authors:
# Madalin Cherciu <[email protected]>
#
# Description:
# A configuration/compilation and installation bash script of GMP, MPFR and MPC.
# The user has to specify only the paths for GMP, MPFR and MPC directories.
#
# P.S. I use it for gcc specific version compilation
#
# Legal Preamble:
#
# This script is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free Software
# Foundation; version 3.
#
# This script is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
# details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, see <https://www.gnu.org/licenses/gpl-3.0.txt>
echo -e "Please specify the path for GMP ..."
read p1
echo -e "Please specify the path for MPFR ..."
read p2
echo -e "Please specify the path for MPC ..."
read p3
echo "Compiling time ..."
echo "GMP compilling ..."
cd $p1
./configure --prefix=${PWD} --disable-shared --enable-static
make && make check && make install
echo "MPFR compilling ..."
cd $p2
./configure --prefix=${PWD} --disable-shared --enable-static --with-gmp-lib=$p1/lib
make && make check && make install
echo "MPC compilling ..."
cd $p3
./configure --prefix=${PWD} --disable-shared --enable-static --with-gmp-lib=$p1/lib --with-mpfr-lib=$p2/lib
make && make check && make install
echo "DONE ..."