This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH committed] Fix build failure with MPFR 2.4.x (gimple-ssa-sprintf.c)
- From: Martin Sebor <msebor at gmail dot com>
- To: Markus Trippelsdorf <markus at trippelsdorf dot de>, gcc-patches at gcc dot gnu dot org
- Date: Tue, 24 Jan 2017 08:55:22 -0700
- Subject: Re: [PATCH committed] Fix build failure with MPFR 2.4.x (gimple-ssa-sprintf.c)
- Authentication-results: sourceware.org; auth=none
- References: <20170124093757.GA288@x4>
On 01/24/2017 02:37 AM, Markus Trippelsdorf wrote:
MPFR_RNDx was introduced in MPFR 3.0.0. Since the minimal version that
gcc checks for is 2.4.0, this leads to a build failure.
The fix is straightforward.
Tested on x86_64-pc-linux-gnu. Committed to trunk as obvious.
* gimple-ssa-sprintf.c (format_floating): Change MPFR_RNDx to
GMP_RNDx for compatibility.
This was changed once before for this reason (in r240350). I forgot
all about it and put it back in my latest patch for some reason. I
don't remember why exactly but I suspect I might have been trying to
overcome some MPFR oddity. It might help to #undef the MPFR_RNDx
macros after including <mpfr.h> to avoid this in the future. In any
event, thanks for the fix.
Martin