Solved my own problem while no one had yet replied. Here is my solution, for anyone who might find it useful: For information about my particular linux distribution, see below (I do not have administrative rights on it).
1. Apparently gcc 4.7.0 is already based on gmp and mpfr, so copy static library file libmpfr.so.1 (and related files) from /usr/lib64 to the mpfr/mpfr/ subdirectory of the ALGLIB.MPFR root directory. 2. Execute in the mpfr/mpfr subdirectory the following command: link libmpfr.so.1 libmpfr.so 3. Also remove the gcc option -lmpn from the compile command near the end of the script-files mpfr/check and mpfr/example. (Apparently, libmpn.so* is no longer needed with this version of gcc.) 4. In the same compile command of the two script-files above, replace the gcc option '-L.' with '-L../mpfr -L../out' to enable the linker to locate the libmpfr.so and libmpalglib.a files. 5. You might also need to add the line: #!/bin/sh at the very beginning of the script-files mpfr/build, mpfr/check, and mpfr/example. Also don't forget to ensure these script-files are executable by yourself (eg., chmod a+x build, etc.) 6. You may now execute the script-files: ./build gcc ./check gcc all ./example gcc minlbfgs_1 Hope it works for you!
My system information: uname -a Linux gwdu101 2.6.32-431.20.3.el6.x86_64 #1 SMP Thu Jun 19 14:01:59 CDT 2014 x86_64 x86_64 x86_64 GNU/Linux
GCC version: gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/cm/shared/apps/gcc/4.7.0/libexec/gcc/x86_64-unknown-linux-gnu/4.7.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../gcc-4.7.0/configure --prefix=/cm/shared/apps/gcc/4.7.0 --enable-languages=c,c++,fortran --with-gmp-include=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-gmp --with-gmp-lib=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-gmp --with-mpc-include=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-mpc/src --with-mpc-lib=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-mpc/src/.libs --with-mpfr-include=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-mpfr/src --with-mpfr-lib=/usr/src/redhat/BUILD/gcc-4.7.0-obj/../gcc-4.7.0/our-mpfr/src/.libs Thread model: posix gcc version 4.7.0 (GCC)
Cheers, h
|