How to reliable detect a MacPorts-ported compiler?
ryandesign at macports.org
Mon Sep 7 18:46:32 PDT 2015
On Sep 7, 2015, at 8:43 PM, Jeffrey Walton wrote:
>>> For Apple, we can detect Apple ported gear with:
>>> $ clang++ -dM -E - < /dev/null | grep -i apple
>>> #define __APPLE_CC__ 6000
>>> #define __APPLE__ 1
>>> #define __VERSION__ "4.2.1 Compatible Apple LLVM 5.1 (clang-503.0.40)"
>>> #define __apple_build_version__ 5030040
>> Well, that's clang, not gcc.
> Right, but the APPLE_CC tells me its an Apple port.
Right: it tells you it is an Apple fork of that compiler.
MacPorts does not fork things. We package the original thing.
More information about the macports-users