Opened 16 months ago

Last modified 13 months ago

#52043 assigned defect

python27 @2.7.12_1 fails to build +universal on Sierra; prevents installation of wine

Reported by: chris@… Owned by: larryv (Lawrence Velázquez)
Priority: High Milestone:
Component: ports Version: 2.3.4
Keywords: sierra haspatch Cc: mkae (Marko Käning), jeremyhu (Jeremy Huddleston Sequoia), ned-deily (Ned Deily), jyrkiwahlstedt, MaddTheSane (C.W. Betts), roberthuston@…, elventear@…, ryandesign (Ryan Schmidt), mayocoko@…
Port: python27, wine, wine-devel, wine-crossover

Description

I am attempting to install wine, and this package fails to build due to the Mac glue attempting to import Quicktime headers, which no longer exist.

Attachments (1)

main.log (113.8 KB) - added by chris@… 16 months ago.
Clean python27 build log

Download all attachments as: .zip

Change History (26)

Changed 16 months ago by chris@…

Clean python27 build log

comment:1 Changed 16 months ago by larryv (Lawrence Velázquez)

  • Owner changed from macports-tickets@… to jwa@…
  • Summary changed from Python27 @2.7.12_1 fails to build +universal on Sierra to python27 @2.7.12_1 fails to build +universal on Sierra

In future port-related tickets, please Cc the maintainers (e.g., port info --maintainers python27), if any.

comment:3 Changed 16 months ago by mkae (Marko Käning)

  • Cc mk@… added

Cc Me!

comment:4 Changed 15 months ago by ryandesign (Ryan Schmidt)

  • Cc ryandesign@… added

Cc Me!

comment:5 Changed 15 months ago by ryandesign (Ryan Schmidt)

  • Cc jeremyhu@… added
  • Keywords haspatch added
  • Port wine wine-devel wine-crossover added
  • Priority changed from Normal to High
  • Summary changed from python27 @2.7.12_1 fails to build +universal on Sierra to python27 @2.7.12_1 fails to build +universal on Sierra; prevents installation of wine

There is a patch attached to the upstream issue but I don't know if that's the best solution. Jeremy, what do you think?

comment:6 follow-up: Changed 15 months ago by jeremyhu (Jeremy Huddleston Sequoia)

AvailabilityMacros.h is super deprecated and should not be used by anything current. Availability.h was added as replacement in 10.5.

__MAC_OS_X_VERSION_MAX_ALLOWED should be checked instead of defined (DEPRECATED_IN_MAC_OS_X_VERSION_10_12_AND_LATER)

They should really have a central config and use that instead. Eg:

#include <Availability.h>
#define APPLE_SUPPORTS_QUICKTIME (__MAC_OS_X_VERSION_MAX_ALLOWED < 101200) && !__LP64__
Last edited 15 months ago by jeremyhu (Jeremy Huddleston Sequoia) (previous) (diff)

comment:7 Changed 15 months ago by larryv (Lawrence Velázquez)

  • Cc nad@… added

comment:8 in reply to: ↑ 6 ; follow-up: Changed 15 months ago by ryandesign (Ryan Schmidt)

Replying to jeremyhu@…:

AvailabilityMacros.h is super deprecated and should not be used by anything current. Availability.h was added as replacement in 10.5.

It would be nice to still be able to build on 10.4...

comment:9 Changed 15 months ago by jeremyhu (Jeremy Huddleston Sequoia)

Ok, then:

#if __has_include(<Availability.h>)
#include <Availability.h>
#define APPLE_SUPPORTS_QUICKTIME (__MAC_OS_X_VERSION_MAX_ALLOWED < 101200) && !__LP64__
#else
#define APPLE_SUPPORTS_QUICKTIME !__LP64__
#endif
Last edited 15 months ago by jeremyhu (Jeremy Huddleston Sequoia) (previous) (diff)

comment:10 Changed 15 months ago by jeremyhu (Jeremy Huddleston Sequoia)

Please use the v2 version of the upstream patch which incorporates my feedback:

http://bugs.python.org/file44693/issue27806_v2.patch

comment:11 in reply to: ↑ 8 Changed 15 months ago by ned-deily (Ned Deily)

Replying to ryandesign@…:

It would be nice to still be able to build on 10.4...

There is another, unrelated issue with building Python 3.6 on 10.4. As of 3.6.0b1, certain features of the C99 standard are used in C modules; as a result, 3.6 no longer compiles with gcc-4.0, the standard in Xcode 2.5 for 10.4. So you'll probably need to add a dependency on a MacPorts-supplied C compiler (gcc-4.2 is fine).

Last edited 15 months ago by ned-deily (Ned Deily) (previous) (diff)

comment:12 Changed 15 months ago by ryandesign (Ryan Schmidt)

We changed the default compiler on Tiger to Apple GCC 4.2 (provided by MacPorts) years ago. If there is another issue with Tiger please file a new ticket.

comment:13 Changed 15 months ago by ned-deily (Ned Deily)

Oh, good. I haven't actually yet tried to install the python36 port on 10.4. One more thing, the v2 patch referred to by Jeremy above needed to be tweaked for gcc-4.2 et al. The final version has been committed here: https://hg.python.org/cpython/rev/4030300fcb18

comment:14 Changed 15 months ago by larryv (Lawrence Velázquez)

  • Cc jwa@… added
  • Owner changed from jwa@… to larryv@…
  • Status changed from new to assigned

r152947, maintainer timeout. I applied the upstream patch but don’t have Sierra available to test; can someone verify that +universal works on Sierra now?

comment:16 Changed 15 months ago by MaddTheSane (C.W. Betts)

  • Cc computers57@… added

Cc Me!

comment:17 Changed 15 months ago by ryandesign (Ryan Schmidt)

That works. Can we apply the same patch to all the other python2x ports, please? (I tested python31 and python36 and they didn't have this problem.)

comment:18 Changed 15 months ago by roberthuston@…

  • Cc roberthuston@… added

Cc Me!

comment:19 Changed 15 months ago by elventear@…

  • Cc elventear@… added

Cc Me!

comment:20 Changed 15 months ago by ryandesign (Ryan Schmidt)

  • Cc ryandesign@… removed

Cc Me!

comment:21 Changed 15 months ago by ryandesign (Ryan Schmidt)

  • Cc ryandesign@… added

Cc Me!

comment:22 Changed 15 months ago by mayocoko@…

  • Cc mayocoko@… added

Cc Me!

comment:23 follow-up: Changed 14 months ago by mf2k (Frank Schima)

This works for me now. Can we close this ticket?

$ port -v installed python27
The following ports are currently installed:
  python27 @2.7.12_1+universal (active) platform='darwin 16' archs='i386 x86_64' date='2016-09-21T20:57:53-0600'

comment:24 in reply to: ↑ 23 Changed 14 months ago by larryv (Lawrence Velázquez)

I would like to keep this open to remind myself to fix the other Python 2 ports also, once I actually upgrade my machine to Sierra.

comment:25 Changed 13 months ago by larryv (Lawrence Velázquez)

In 03f6ca7c/macports-ports:

python26: Improve check for QuickTime/QuickTime.h

This fixes 32-bit builds on Sierra, which removed that header.

See: #52043

Note: See TracTickets for help on using tickets.