How to reliable detect a MacPorts-ported compiler?

Jeffrey Walton noloader at
Tue Sep 8 20:56:38 PDT 2015

>> Thanks again Ryan.
>> Is there a #define so we can detect it in the source code?
> Not that I'm aware of.

OK, thanks.

That's kind of a problem. The problem occurs when a user includes the
library. We (the library) can get into a good state at build time by
shell'ing out and detecting MacPorts, and then defining something to
avoid the code path. But we can't get users of the library in a good
state because we don't control their make or command line.

Does MacPorts offer anything in the preprocessor we can key on?


More information about the macports-users mailing list