Merge pull request #307573 from NickCao/qt6-debug

qt6: drop debug and developerBuild in favor of cmakeBuildType

authored by Nick Cao and committed by GitHub ecc54070 e39c9004

-34
-6
pkgs/development/libraries/qt-6/default.nix
··· 15 15 , buildPackages 16 16 , python3 17 17 , config 18 - 19 - # options 20 - , developerBuild ? false 21 - , debug ? false 22 18 }: 23 19 24 20 let ··· 47 43 qtbase = callPackage ./modules/qtbase.nix { 48 44 withGtk3 = !stdenv.hostPlatform.isMinGW; 49 45 inherit (srcs.qtbase) src version; 50 - inherit developerBuild; 51 46 inherit (darwin.apple_sdk_11_0.frameworks) 52 47 AGL AVFoundation AppKit Contacts CoreBluetooth EventKit GSS MetalKit; 53 48 patches = [ ··· 197 192 name = "qmake6-hook"; 198 193 propagatedBuildInputs = [ qtbase.dev ]; 199 194 substitutions = { 200 - inherit debug; 201 195 fix_qmake_libtool = ./hooks/fix-qmake-libtool.sh; 202 196 }; 203 197 } ./hooks/qmake-hook.sh)
-6
pkgs/development/libraries/qt-6/hooks/qmake-hook.sh
··· 18 18 "NIX_OUTPUT_PLUGIN=${!outputBin}/${qtPluginPrefix:?}" 19 19 ) 20 20 21 - if [ -n "@debug@" ]; then 22 - qmakeFlags+=("CONFIG+=debug") 23 - else 24 - qmakeFlags+=("CONFIG+=release") 25 - fi 26 - 27 21 qmakeFlags+=("${qmakeFlags_orig[@]}") 28 22 } 29 23 prePhases+=" qmakePrePhase"
-14
pkgs/development/libraries/qt-6/hooks/qtbase-setup-hook.sh
··· 15 15 . @fix_qt_builtin_paths@ 16 16 . @fix_qt_module_paths@ 17 17 18 - # Disable debug symbols if qtbase was built without debugging. 19 - # This stops -dev paths from leaking into other outputs. 20 - if [ -z "@debug@" ]; then 21 - NIX_CFLAGS_COMPILE="${NIX_CFLAGS_COMPILE-}${NIX_CFLAGS_COMPILE:+ }-DQT_NO_DEBUG" 22 - fi 23 - 24 - # Integration with CMake: 25 - # Set the CMake build type corresponding to how qtbase was built. 26 - if [ -n "@debug@" ]; then 27 - cmakeBuildType="Debug" 28 - else 29 - cmakeBuildType="Release" 30 - fi 31 - 32 18 # Build tools are often confused if QMAKE is unset. 33 19 export QMAKE=@out@/bin/qmake 34 20
-8
pkgs/development/libraries/qt-6/modules/qtbase.nix
··· 92 92 # options 93 93 , libGLSupported ? stdenv.hostPlatform.isLinux 94 94 , libGL 95 - , debug ? false 96 - , developerBuild ? false 97 95 , qttranslations ? null 98 96 }: 99 97 100 98 let 101 - debugSymbols = debug || developerBuild; 102 99 isCrossBuild = !stdenv.buildPlatform.canExecute stdenv.hostPlatform; 103 100 in 104 101 stdenv.mkDerivation rec { 105 102 pname = "qtbase"; 106 103 107 104 inherit src version; 108 - 109 - debug = debugSymbols; 110 105 111 106 propagatedBuildInputs = [ 112 107 libxml2 ··· 195 190 CoreBluetooth 196 191 ] 197 192 ++ lib.optional withGtk3 gtk3 198 - ++ lib.optional developerBuild gdb 199 193 ++ lib.optional (cups != null && lib.meta.availableOn stdenv.hostPlatform cups) cups 200 194 ++ lib.optional (libmysqlclient != null && !stdenv.hostPlatform.isMinGW) libmysqlclient 201 195 ++ lib.optional (postgresql != null && lib.meta.availableOn stdenv.hostPlatform postgresql) postgresql; ··· 265 259 # FIXME: not sure why this isn't added automatically? 266 260 patchelf --add-rpath "${libmysqlclient}/lib/mariadb" $out/${qtPluginPrefix}/sqldrivers/libqsqlmysql.so 267 261 ''; 268 - 269 - dontStrip = debugSymbols; 270 262 271 263 dontWrapQtApps = true; 272 264