diff --git a/scripts/chapter8/8.20-mpfr.sh b/scripts/chapter8/8.20-mpfr.sh new file mode 100644 index 0000000..d28f6ec --- /dev/null +++ b/scripts/chapter8/8.20-mpfr.sh @@ -0,0 +1,33 @@ +#!/bin/bash + +cd /sources +tar xf mpfr-4.1.0.tar.xz +cd mpfr-4.1.0 + +./configure --prefix=/usr \ + --disable-static \ + --enable-thread-safe \ + --docdir=/usr/share/doc/mpfr-4.1.0 + +if [ $? -ne 0 ] +then + exit 1 +fi + +make -j5 + +if [ $? -ne 0 ] +then + exit 1 +fi + +make html + +make check + +make install +make install-html + +cd /sources +rm -rf mpfr-4.1.0 + diff --git a/scripts/main.sh b/scripts/main.sh index eedfed7..393dc36 100644 --- a/scripts/main.sh +++ b/scripts/main.sh @@ -774,3 +774,15 @@ then stop_script "chapter8/8.19-gmp.sh" fi +# Chapter 8.20 +# ============ +echo "Building MPFR" +su -c "bash $SCRIPT/chapter8/8.20-mpfr.sh" + +# Exit on error +check_exit_code +if [ $exit_status -ne 0 ] +then + stop_script "chapter8/8.20-mpfr.sh" +fi +