The gfortran shipped with the macOS binaries depends on the specific location of the macOS SDK (specifically, libSystem). Even within the same macOS version, this location varies depending on whether the full XCode or only the XCode command line tools are installed.
Concretely, in the macOS binary sage-8.8-OSX_10.14.5-x86_64, local/bin/gfortran -v reports that it was configured with --with-sysroot=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk. My target system, however, only has the command line tools:
The gfortran shipped with the macOS binaries depends on the specific location of the macOS SDK (specifically, libSystem). Even within the same macOS version, this location varies depending on whether the full XCode or only the XCode command line tools are installed.
Concretely, in the macOS binary sage-8.8-OSX_10.14.5-x86_64,
local/bin/gfortran -v
reports that it was configured with--with-sysroot=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk
. My target system, however, only has the command line tools:As a consequence, gfortran, for recompiling packages
openblas
orscipy
, fails on this system with this error message:(The scipy recompilation is triggered, for example, if one reinstalls python2 following standard recipes such as http://sageregina.unhyperbolic.org/mac_os_and_ssl.html to enable SSL.)
Perhaps the binary package should supply
--sysroot
togfortran
at runtime.