Qt5.7 build fails with Xcode 8 - KDE Bug #369161
ClosedPublic

Authored by pkouame on Sep 30 2016, 6:44 PM.

Details

Summary

On macOS, Qt5.7 verifies the Xcode install by running an outdated command xcrun --find xcrun.
This should now read xcrun --find xcodebuild. Two files in the Qt installation are affected.
The bug is acknowledged by Qt and slated for a possible fix in 5.7.1.
See qt/qtbase.git
Two patches are injected in the patch set if the condition is detected.
Some additional checks are implemented to provide both an early warning of the inadequate build environment and future proof this patch: this cmakelists should work even after an upgrade to 5.7.1.
Since Qt is a large project an attempt is also made to parallelize the ext_qt build automatically.

This patch only affects macOS users using the default xcode toolchain. Which should be a majority of macOS users.

NOTES:
-This has not been tested under alternate xcode toolchains (custom gcc or clang).
-The win32 and other nix paths have been left untouched, so should be unaffected by any of this.

My environment:
krita master git (10af108)
ext_qt qt5.7 rebuilt and patched
xcode 8
macOS Sierra
macPro 3,1

Test Plan

1- cmake ext_qt according to 3rdparty release notes
2- verify that qt builds correctly
3- verify that krita runs correctly

Diff Detail

Repository
R37 Krita
Lint
Lint Skipped
Unit
Unit Tests Skipped
pkouame updated this revision to Diff 7011.Sep 30 2016, 6:44 PM
pkouame retitled this revision from to Qt5.7 build fails with Xcode 8 - KDE Bug #369161.
pkouame updated this object.
pkouame edited the test plan for this revision. (Show Details)
pkouame added reviewers: rempt, dkazakov, woltherav.
pkouame set the repository for this revision to R37 Krita.
rempt accepted this revision.Oct 7 2016, 9:25 AM
rempt edited edge metadata.

I cannot test the patch myself, since I don't have Sierra. On my El Capitan macbook, I first get this output:

  • /Users/boud/master/deps:Identified Xcode Version: 7.3.1
  • /Users/boud/master/deps:Found XCSELECT_PROGRAM as /usr/bin/xcode-select
  • /Users/boud/master/deps:Found XCRUN_PROGRAM as /usr/bin/xcrun
  • /Users/boud/master/deps:xcrun test failed with status 64
  • /Users/boud/master/deps:Parallelized make: make;-j6

But configuring Qt 5.7 works fine, so I think you push this patch.

This revision is now accepted and ready to land.Oct 7 2016, 9:25 AM
dkazakov closed this revision.Apr 18 2018, 10:17 AM

The patch has been pushed by the author in 54c43f8ff43af7a1b7981bb28dde65543455a5ac :)