Commit e34775b6 authored by Niklas Korz's avatar Niklas Korz
Browse files

qt6: prevent Xcode version sniffing

Qt tries to detect the running Xcode version through `xcrun xcodebuild
-version`.
This fails when xcbuild is not included in the dependencies, and is also
unnecessary as the value is only used for the Xcode min version check
that we explicitly disable already.
parent bdfd0f2a
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -269,6 +269,10 @@ stdenv.mkDerivation rec {
    ++ lib.optionals stdenv.hostPlatform.isDarwin [
      "-DQT_FEATURE_rpath=OFF"
      "-DQT_NO_XCODE_MIN_VERSION_CHECK=ON"
      # This is only used for the min version check, which we disabled above.
      # When this variable is not set, cmake tries to execute xcodebuild
      # to query the version.
      "-DQT_INTERNAL_XCODE_VERSION=0.1"
    ]
    ++ lib.optionals isCrossBuild [
      "-DQT_HOST_PATH=${pkgsBuildBuild.qt6.qtbase}"
+7 −1
Original line number Diff line number Diff line
@@ -42,7 +42,13 @@ stdenv.mkDerivation (
      # don't leak OS version into the final output
      # https://bugreports.qt.io/browse/QTBUG-136060
      [ "-DCMAKE_SYSTEM_VERSION=" ]
      ++ lib.optional stdenv.hostPlatform.isDarwin "-DQT_NO_XCODE_MIN_VERSION_CHECK=ON"
      ++ lib.optionals stdenv.hostPlatform.isDarwin [
        "-DQT_NO_XCODE_MIN_VERSION_CHECK=ON"
        # This is only used for the min version check, which we disabled above.
        # When this variable is not set, cmake tries to execute xcodebuild
        # to query the version.
        "-DQT_INTERNAL_XCODE_VERSION=0.1"
      ]
      ++ args.cmakeFlags or [ ];

    moveToDev = false;