summary refs log tree commit diff
diff options
context:
space:
mode:
authorVictor Fuentes <vmfuentes64@gmail.com>2022-04-13 23:34:30 -0400
committerVictor Fuentes <vmfuentes64@gmail.com>2022-05-03 12:19:21 -0400
commit057f88b3d265cf758e1cc251ef18c1404127281d (patch)
tree6382bb435ff2a0161b134292676d8c08f01879d9
parentbcb4456920eadfcaf7ef430abf0c5b2ae159a6d6 (diff)
downloadnixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar.gz
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar.bz2
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar.lz
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar.xz
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.tar.zst
nixpkgs-057f88b3d265cf758e1cc251ef18c1404127281d.zip
kpmcore: 4.2.0 -> 22.04.0
-rw-r--r--pkgs/development/libraries/kpmcore/default.nix28
1 files changed, 10 insertions, 18 deletions
diff --git a/pkgs/development/libraries/kpmcore/default.nix b/pkgs/development/libraries/kpmcore/default.nix
index c3621d37587..81109194356 100644
--- a/pkgs/development/libraries/kpmcore/default.nix
+++ b/pkgs/development/libraries/kpmcore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, lib, fetchurl, fetchpatch, extra-cmake-modules
+{ stdenv, lib, fetchurl, extra-cmake-modules
 , qca-qt5, kauth, kio, polkit-qt, qtbase
 , util-linux
 }:
@@ -6,25 +6,14 @@
 stdenv.mkDerivation rec {
   pname = "kpmcore";
   # NOTE: When changing this version, also change the version of `partition-manager`.
-  version = "4.2.0";
+  version = "22.04.0";
 
   src = fetchurl {
-    url = "mirror://kde/stable/${pname}/${version}/src/${pname}-${version}.tar.xz";
-    hash = "sha256-MvW0CqvFZtzcJlya6DIpzorPbKJai6fxt7nKsKpJn54=";
+    url = "mirror://kde/stable/release-service/${version}/src/${pname}-${version}.tar.xz";
+    hash = "sha256-sO8WUJL6072H1ghMZd7j0xNMwEn4bJF5PXMhfEb2jbs=";
   };
 
-  patches = [
-    # Fix build with `kcoreaddons` >= 5.77.0
-    (fetchpatch {
-      url = "https://github.com/KDE/kpmcore/commit/07e5a3ac2858e6d38cc698e0f740e7a693e9f302.patch";
-      sha256 = "sha256-LYzea888euo2HXM+acWaylSw28iwzOdZBvPBt/gjP1s=";
-    })
-    # Fix crash when `fstab` omits mount options.
-    (fetchpatch {
-      url = "https://github.com/KDE/kpmcore/commit/eea84fb60525803a789e55bb168afb968464c130.patch";
-      sha256 = "sha256-NJ3PvyRC6SKNSOlhJPrDDjepuw7IlAoufPgvml3fap0=";
-    })
-  ];
+  nativeBuildInputs = [ extra-cmake-modules ];
 
   buildInputs = [
     qca-qt5
@@ -35,10 +24,13 @@ stdenv.mkDerivation rec {
     util-linux # Needs blkid in configure script (note that this is not provided by util-linux-compat)
   ];
 
-  nativeBuildInputs = [ extra-cmake-modules ];
-
   dontWrapQtApps = true;
 
+  preConfigure = ''
+    substituteInPlace src/util/CMakeLists.txt \
+      --replace \$\{POLKITQT-1_POLICY_FILES_INSTALL_DIR\} $out/share/polkit-1/actions
+  '';
+
   meta = with lib; {
     description = "KDE Partition Manager core library";
     homepage = "https://invent.kde.org/system/kpmcore";