os.major etc. on Linux

Ryan Schmidt ryandesign at macports.org
Thu May 12 21:39:41 PDT 2016


On May 12, 2016, at 5:37 AM, René J.V. Bertin wrote:

> On Thursday May 12 2016 11:57:21 Rainer Müller wrote:
> 
>> I would consider this a bug.
> 
> Me too, if we're sure it isn't a feature ;)
> 
>> We take this directly from
>> $tcl_platform(osVersion), which is equivalent to `uname -r`.
>> 
>> As this assumption is wrong for Linux, this is the place where it needs
>> to be fixed:
>> 
>> https://trac.macports.org/browser/trunk/base/src/macports1.0/macports.tcl?rev=147347#L633
> 
> Looks familiar indeed. That's where I hard-code os_major to 3.
> Do you have any suggestion on how to fix this, so I can propose a patch?
> 
> Side-ways related: why is os_arch reset to i386 from x86_64 on line 636? From what I've seen that causes packages to be labelled and registered as i386 (i.e. 32bit) when built on 64bit linux.

In MacPorts, os_arch is i386 on all Intel Macs (32-bit and 64-bit), and ppc on all PowerPC Macs (32-bit and 64-bit). Changing that now would break all ports that rely on the existing long-standing behavior.




More information about the macports-dev mailing list