[46483] trunk/dports/_resources/port1.0/group/muniversal-1.0.tcl

Toby Peterson toby at macports.org
Fri Feb 6 14:31:02 PST 2009


On Fri, Feb 6, 2009 at 9:57 AM, Joshua Root <jmr at macports.org> wrote:
> Toby Peterson wrote:
>> On Thu, Feb 5, 2009 at 10:51 PM, Ryan Schmidt <ryandesign at macports.org> wrote:
>>> On Feb 6, 2009, at 00:01, Marcus Calhoun-Lopez wrote:
>>>
>>>> Joshua Root <jmr at ...> writes:
>>>>
>>>>> There's the hw.cpu64bit_capable sysctl variable, on Leopard.
>>>> Just what I was looking for.
>>>> Thank you.
>>>>
>>>> I only have Leopard machines to test on, however.
>>>> Does anyone know if the code:
>>>> if { [exec "/usr/sbin/sysctl" "-n" "hw.cpu64bit_capable"] != "1" } {
>>>> .
>>>> .
>>>> .
>>>> }
>>>> works on all platforms where universal binaries might be built?
>>> Hmm. Well, on Tiger it says:
>>>
>>> /usr/sbin/sysctl -n hw.cpu64bit_capable
>>> second level name cpu64bit_capable in hw.cpu64bit_capable is invalid
>>>
>>> So if you were to write code around that response, you would presumably
>>> assume that 64-bit binaries cannot be built on Tiger, which isn't
>>> necessarily so.
>>>
>>> Maybe there's a way we can ask about the processor family.
>>
>> I think the easiest solution is to simply match the architectures of libSystem.
>
> No good, it has ppc64 even on a G4.

Eh, I guess I missed the point of this thread. Ignore me.

- Toby


More information about the macports-dev mailing list