Compilers and universal flag
Joshua Root
jmr at macports.org
Sun May 13 06:38:16 PDT 2012
On 2012-5-13 22:41 , Vincent Habchi wrote:
> Folks,
>
> I am not aware this subject has been discussed before; if it has, I apologize for pointing out twice the same issue.
>
> It seems to me Macports doesn’t deal the right way with universal and compilers. AFAIK, the +universal flag is needed (at least for GCC4.x) in order for the compiler to be able to generate universal images (m32/m64). Side effect is that the compiler itself is built as a universal binary, which may or – most of the time – may not be desired. There are few cases where a universal compiler is needed; conversely, universal capable compiler can often be useful.
>
> Therefore, I was about to suggest that we introduce a special universal option (e.g. universal-binary) to tell MacPorts we want the compiler be built universal, as opposed to the classical +universal option that would tell please build me a compiler that is able to generate universal binaries. This way, the dependency chain would not be broken (+universal binary would indeed need a +universal compiler), but the user would have an additional degree of freedom when building his/her compiler.
>
> Opinion?
Actually, nobody bothered making gcc4x build truly universal. The
universal variant just enables multilib.
What you suggest amounts to distinguishing between host and target
archs, and thus also distinguishing between ports that even have target
archs (i.e. compilers and toolchains) and those that don't. Then you'd
have to be able to specify whether each dependent wants the compiler to
build it or to use the compiler to build something else, and match up
host->target or target->target as appropriate.
I doubt it's worth the effort.
- Josh
More information about the macports-dev
mailing list