]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Define MPFR_USE_INTMAX_T so that mpfr.h assumes intmax_t is available.
authorJohn Baldwin <jhb@FreeBSD.org>
Thu, 30 Nov 2017 00:28:01 +0000 (16:28 -0800)
committerJohn Baldwin <jhb@FreeBSD.org>
Thu, 30 Nov 2017 00:28:01 +0000 (16:28 -0800)
mpfr.h uses a non-portable test to guess if intmax_t is available and
if API functions using intmax_t should be exposed.  Define
MPFR_USE_INTMAX_T to override the non-portable test and always expose
these functions.  This fixes the build on platforms where the test
guesses incorrectly.

gdb/ChangeLog:

* target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.

gdb/ChangeLog
gdb/target-float.c

index ca8c5dfaf13f46f869d5f0b2e466aa9171bea797..d6cbba8aeb126f9ed5f3fb9b923ef7ddf327ce5f 100644 (file)
@@ -1,3 +1,7 @@
+2017-11-29  John Baldwin  <jhb@FreeBSD.org>
+
+       * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
+
 2017-11-29  Joel Brobecker  <brobecker@adacore.com>
 
        * ada-lang.c (to_fixed_range_type): Make sure that the size
index 32237ec9d9364b151cf1ba7d1a7e974a8d89411e..b40b6416c1ca55c00ebff65a11183f913bc0eebd 100644 (file)
@@ -1147,6 +1147,8 @@ host_float_ops<T>::compare (const gdb_byte *x, const struct type *type_x,
 
 #ifdef HAVE_LIBMPFR
 
+#define MPFR_USE_INTMAX_T
+
 #include <mpfr.h>
 
 class mpfr_float_ops : public target_float_ops