From 02f013b8a48406cf43dd530e7e6360c470453108 Mon Sep 17 00:00:00 2001 From: Alyssa Ross Date: Wed, 12 May 2021 09:13:47 +0000 Subject: [PATCH 1/2] cmakeWithQt4Gui: drop Support for Qt 4 was removed in CMake 3.19.0: https://cmake.org/cmake/help/latest/release/3.19.html#deprecated-and-removed-features --- .../tools/build-managers/cmake/default.nix | 12 +++--------- pkgs/top-level/all-packages.nix | 1 - 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/pkgs/development/tools/build-managers/cmake/default.nix b/pkgs/development/tools/build-managers/cmake/default.nix index d1460507466..b04eac35b05 100644 --- a/pkgs/development/tools/build-managers/cmake/default.nix +++ b/pkgs/development/tools/build-managers/cmake/default.nix @@ -7,19 +7,14 @@ , useSharedLibraries ? (!isBootstrap && !stdenv.isCygwin) , useOpenSSL ? !isBootstrap, openssl , useNcurses ? false, ncurses -, useQt4 ? false, qt4 , withQt5 ? false, qtbase }: -assert withQt5 -> useQt4 == false; -assert useQt4 -> withQt5 == false; - stdenv.mkDerivation (rec { pname = "cmake" + lib.optionalString isBootstrap "-boot" + lib.optionalString useNcurses "-cursesUI" - + lib.optionalString withQt5 "-qt5UI" - + lib.optionalString useQt4 "-qt4UI"; + + lib.optionalString withQt5 "-qt5UI"; version = "3.19.7"; src = fetchurl { @@ -53,7 +48,6 @@ stdenv.mkDerivation (rec { ++ lib.optionals useSharedLibraries [ bzip2 curlMinimal expat libarchive xz zlib libuv rhash ] ++ lib.optional useOpenSSL openssl ++ lib.optional useNcurses ncurses - ++ lib.optional useQt4 qt4 ++ lib.optional withQt5 qtbase; propagatedBuildInputs = lib.optional stdenv.isDarwin ps; @@ -73,7 +67,7 @@ stdenv.mkDerivation (rec { configureFlags = [ "--docdir=share/doc/${pname}${version}" ] ++ (if useSharedLibraries then [ "--no-system-jsoncpp" "--system-libs" ] else [ "--no-system-libs" ]) # FIXME: cleanup - ++ lib.optional (useQt4 || withQt5) "--qt-gui" + ++ lib.optional withQt5 "--qt-gui" # Workaround https://gitlab.kitware.com/cmake/cmake/-/issues/20568 ++ lib.optionals stdenv.hostPlatform.is32bit [ "CFLAGS=-D_FILE_OFFSET_BITS=64" @@ -124,7 +118,7 @@ stdenv.mkDerivation (rec { configuration files, and generate native makefiles and workspaces that can be used in the compiler environment of your choice. ''; - platforms = if useQt4 then qt4.meta.platforms else platforms.all; + platforms = platforms.all; maintainers = with maintainers; [ ttuegel lnl7 ]; license = licenses.bsd3; }; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b76f1b53f9e..bfa3e0c07b5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12762,7 +12762,6 @@ in cmakeCurses = cmake.override { useNcurses = true; }; cmakeWithGui = cmakeCurses.override { withQt5 = true; }; - cmakeWithQt4Gui = cmakeCurses.override { useQt4 = true; }; cmake-format = python3Packages.callPackage ../development/tools/cmake-format { }; From 20f595774df8527d8fbb88d0dd456745254a625c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Sat, 22 May 2021 15:50:44 +0200 Subject: [PATCH 2/2] cmakeWithQt4Gui: add a throw-alias --- pkgs/top-level/aliases.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index b8a804f9aaa..6a9d88d910a 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -114,6 +114,7 @@ mapAliases ({ clangAnalyzer = clang-analyzer; # added 2015-02-20 clawsMail = claws-mail; # added 2016-04-29 clutter_gtk = clutter-gtk; # added 2018-02-25 + cmakeWithQt4Gui = throw "cmakeWithQt4Gui has been removed in favor of cmakeWithGui (Qt 5)"; # added 2021-05 codimd = hedgedoc; # added 2020-11-29 compton = picom; # added 2019-12-02 compton-git = compton; # added 2019-05-20