0

I'm trying to install GNU MPFR. I've downloaded the source, cd'd into it and typed ./configure, which goes through a load of checks (which are all okay, as far as I can see.) The problem occurs when it gets to the config.status: creating Makefile stage. This is what it says:

configure: creating ./config.status
config.status: creating Makefile
dyld: Library not loaded: /usr/local/opt/mpfr/lib/libmpfr.4.dylib
  Referenced from: /usr/local/bin/gawk
  Reason: image not found
./config.status: line 1108: 36325 Done(141)               eval sed \"\$ac_sed_extra\" "$ac_file_inputs"
     36326 Abort trap: 6           | $AWK -f "$ac_tmp/subs.awk" > $ac_tmp/out
config.status: error: could not create Makefile

Isn't that weird? I'm trying to install libmpfr 4, which apparently requires libmpfr.4.dylib to be loaded.

Any suggestions?

0

First, libmpfr.4.dylib comes from GNU MPFR 3.x (both 3.0.x and 3.1.x), while libmpfr.6.dylib comes from GNU MPFR 4.0.x (currently the latest version), which is ABI-incompatible with the previous MPFR versions.

Note: The software version (3.0.x, 3.1.x, 4.0.x, etc.) and library versioning (what yields the number before .dylib) should not be mixed up (detailed information on how these things work).

So, your /usr/local/bin/gawk was built against MPFR 3.x, which seems to have been removed. I suspect that it had been replaced by MPFR 4.x (both library versions are co-installable but some packaging systems do not support this kind of things). You can check whether /usr/local/opt/mpfr/lib/libmpfr.6.dylib is present. If this is the case, you don't need to install GNU MPFR again, but you still need to do the things below.

The problem is that you have old software, like gawk, that was built against MPFR 3.x, which is no longer present. A solution is to uninstall such software (so that it won't trigger any error) and reinstall it against MPFR 4.x.

Note: If MPFR 4.x is not installed, you will need to install it, but some tools like gawk may already be provided in compiled form by your system (perhaps old versions, but this would be sufficient for the bootstrap). Also, avoid mixing build/package systems. If you installed MPFR via Homebrew, do this too for gawk; and sometimes, packages need to be reinstalled (example concerning MPFR 3.x vs 4.x).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.