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