diff options
Diffstat (limited to 'gdb/configure')
-rwxr-xr-x | gdb/configure | 99 |
1 files changed, 90 insertions, 9 deletions
diff --git a/gdb/configure b/gdb/configure index b572d414ca..2129f2a266 100755 --- a/gdb/configure +++ b/gdb/configure @@ -885,7 +885,12 @@ with_jit_reader_dir with_expat with_libexpat_prefix with_mpfr +with_mpfr_include +with_mpfr_lib with_libmpfr_prefix +with_gmp +with_gmp_include +with_gmp_lib with_python with_guile enable_source_highlight @@ -1614,9 +1619,20 @@ Optional Packages: --with-expat include expat support (auto/yes/no) --with-libexpat-prefix[=DIR] search for libexpat in DIR/include and DIR/lib --without-libexpat-prefix don't search for libexpat in includedir and libdir - --with-mpfr include MPFR support (auto/yes/no) + --with-mpfr=PATH specify prefix directory for installed MPFR package. + Equivalent to --with-mpfr-include=PATH/include plus + --with-mpfr-lib=PATH/lib + --with-mpfr-include=PATH + specify directory for installed MPFR include files + --with-mpfr-lib=PATH specify directory for the installed MPFR library --with-libmpfr-prefix[=DIR] search for libmpfr in DIR/include and DIR/lib --without-libmpfr-prefix don't search for libmpfr in includedir and libdir + --with-gmp=PATH specify prefix directory for the installed GMP + package. Equivalent to + --with-gmp-include=PATH/include plus + --with-gmp-lib=PATH/lib + --with-gmp-include=PATH specify directory for installed GMP include files + --with-gmp-lib=PATH specify directory for the installed GMP library --with-python[=PYTHON] include python support (auto/yes/no/<python-program>) --with-guile[=GUILE] include guile support @@ -9810,23 +9826,35 @@ done fi +# Check for MPFR (and its dependency GMP) +mpfrlibs= +mpfrinc= + + # Check whether --with-mpfr was given. if test "${with_mpfr+set}" = set; then : withval=$with_mpfr; -else - with_mpfr=auto fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use MPFR" >&5 -$as_echo_n "checking whether to use MPFR... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_mpfr" >&5 -$as_echo "$with_mpfr" >&6; } -if test "${with_mpfr}" = no; then +# Check whether --with-mpfr-include was given. +if test "${with_mpfr_include+set}" = set; then : + withval=$with_mpfr_include; +fi + + +# Check whether --with-mpfr-lib was given. +if test "${with_mpfr_lib+set}" = set; then : + withval=$with_mpfr_lib; +fi + + +#For backwards-compatiblity we also support --with-mpfr={no|yes|auto} +if test "x$with_mpfr" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: MPFR support disabled; some features may be unavailable." >&5 $as_echo "$as_me: WARNING: MPFR support disabled; some features may be unavailable." >&2;} HAVE_LIBMPFR=no -else +elif test "x$with_mpfr" = xyes -o "x$with_mpfr" = xauto -o "x$with_mpfr" = x -o "x$with_mpfr" = x; then @@ -10298,6 +10326,59 @@ $as_echo "$LIBMPFR" >&6; } $as_echo "$as_me: WARNING: MPFR is missing or unusable; some features may be unavailable." >&2;} fi fi +elif test "x$with_mpfr" != x; then + mpfrlib="-L$with_mpfr/lib -lmpfr" + mpfrinc="-I$with_mpfr/include" +fi + +if test "x$with_mpfr_include" != x; then + mpfrlib="-lmpfr" + mpfrinc="-I$with_mpfr_include" +fi +if test "x$with_mpfr_lib" != x; then + mpfrlib="-L$with_mpfr_lib -lmpfr" +fi + + +# Check whether --with-gmp was given. +if test "${with_gmp+set}" = set; then : + withval=$with_gmp; +fi + + +# Check whether --with-gmp-include was given. +if test "${with_gmp_include+set}" = set; then : + withval=$with_gmp_include; +fi + + +# Check whether --with-gmp-lib was given. +if test "${with_gmp_lib+set}" = set; then : + withval=$with_gmp_lib; +fi + + + +if test "x$with_gmp" != x; then + mpfrlib="$mpfrlib -L$with_gmp/lib -lgmp" + mpfrinc="$mpfrinc -I$with_gmp/include" +fi +if test "x$with_gmp_include" != x; then + mpfrlib="$mpfrlib -lgmp" + mpfrinc="$mpfrinc -I$with_gmp_include" +fi +if test "x$with_gmp_lib" != x; then + mpfrlib="$mpfrlib -L$with_gmp_lib -lgmp" +fi + +if test "x$mpfrlib" != x; then + HAVE_LIBMPFR=yes + + $as_echo "#define HAVE_LIBMPFR 1" >>confdefs.h + + LIBMPFR="$mpfrlib" + + CPPFLAGS="$CPPFLAGS $mpfrinc" fi # --------------------- # |