The MPFR library is a C library for multiple-precision floating-point computations with correct rounding.
This package requires compiler variables to be set for the target in the environment.
export CC="${CLFS_TARGET}-gcc" export CXX="${CLFS_TARGET}-g++" export AR="${CLFS_TARGET}-ar" export AS="${CLFS_TARGET}-as" export RANLIB="${CLFS_TARGET}-ranlib" export LD="${CLFS_TARGET}-ld" export STRIP="${CLFS_TARGET}-strip"
The following patch contains a number of updates to the 2.4.1 branch by the MPFR developers:
patch -Np1 -i ../mpfr-2.4.1-branch_update-2.patch
Prepare MPFR for compilation:
./configure --prefix=/usr --enable-shared \ --build=${CLFS_HOST} --host=${CLFS_TARGET} \ --with-gmp-lib=${CLFS}/usr/lib
Compile the package:
make
Install the package:
make DESTDIR=${CLFS} install
At this time, libtool does not support searching a sysroot for libraries. Leaving the .la files in place will cause libtool to look in the wrong place for libraries. These files are not required for linking on linux. Remove them with the following command:
rm -v ${CLFS}/usr/lib/libmpfr.la