[MacPorts] #45832: defect: policykit 0.112_1 cannot be built on PPC Tiger and Leopard because it needs Clang 3.4 which cannot be built

MacPorts noreply at macports.org
Mon Oct 12 06:44:33 PDT 2015


#45832: defect: policykit 0.112_1 cannot be built on PPC Tiger and Leopard because
it needs Clang 3.4 which cannot be built
------------------------------+----------------------
  Reporter:  Peter_Dyballa@…  |      Owner:  devans@…
      Type:  defect           |     Status:  new
  Priority:  Normal           |  Milestone:
 Component:  ports            |    Version:  2.3.2
Resolution:                   |   Keywords:  haspatch
      Port:  policykit        |
------------------------------+----------------------

Comment (by Peter_Dyballa@…):

 Replying to [comment:20 ryandesign@…]:
 >
 > I could not, for example, find a bug report in
 [https://bugzilla.mozilla.org/ Mozilla's Bugzilla] about the use of
 `_SC_NPROCESSORS_ONLN`. A quick Google search did reveal
 [http://www.cprogramming.com/snippets/source-code/find-the-number-of-cpu-
 cores-for-windows-mac-or-linux this code snippet] purporting to show a
 Mac-compatible equivalent.

 unistd.h does not contain a definition of _SC_NPROCESSORS_ONLN. Another
 option to provide the value would be, taken from the command 'sysctl -b
 hw.availcpu | awk '{print $NF}'' to "patch" jsgc.cpp. In Shell it would be
 something like that:

 {{{
  FROM='sysconf(_SC_NPROCESSORS_ONLN)'
    TO=`sysctl -b hw.availcpu | awk '{print $NF}'`

 sed -ie s/$FROM/${TO}L/ mozjs17.0.0/js/src/jsgc.cpp
 }}}

 Maybe hw.logicalcpu or hw.logicalcpu_max or simple hw.ncpu are better
 names to determine the number of (available) CPU cores.

 Anyway, I think I'm going to try the code snippet. (Because I also found a
 cure for the not building policykit 0.113_1 – not yet reported.)

-- 
Ticket URL: <https://trac.macports.org/ticket/45832#comment:24>
MacPorts <https://www.macports.org/>
Ports system for OS X


More information about the macports-tickets mailing list