qt5.qtwebengine: disable platform check using patches

The previous code using substituteInPlace was broken for both 5.9 and
5.11 (latter was broken after a minor release bump). Using patches
should make things fail loudly and prevent modules/qtwebengine.nix from
being littered with version checks.

The patch for 5.12 is only tested to apply.
This commit is contained in:
Dmitry Kalinkin
2019-03-26 16:30:50 -04:00
parent b0f4ef9127
commit 1809832958
7 changed files with 117 additions and 14 deletions
@@ -67,18 +67,8 @@ qtModule {
src/3rdparty/chromium/gpu/config/gpu_info_collector_linux.cc
''
+ optionalString stdenv.isDarwin (''
# Remove annoying xcode check
substituteInPlace mkspecs/features/platform.prf \
--replace "lessThan(QMAKE_XCODE_VERSION, 7.3)" false \
--replace "/usr/bin/xcodebuild" "xcodebuild"
substituteInPlace src/3rdparty/chromium/build/mac_toolchain.py \
--replace "/usr/bin/xcode-select" "xcode-select"
substituteInPlace src/core/config/mac_osx.pri \
--replace /usr ${stdenv.cc} \
--replace "isEmpty(QMAKE_MAC_SDK_VERSION)" false
--replace /usr ${stdenv.cc}
''
# TODO remove when new Apple SDK is in
+ (if lib.versionOlder qtCompatVersion "5.11" then ''