diff options
author | rewine <lhongxu@outlook.com> | 2023-03-22 00:04:44 +0800 |
---|---|---|
committer | rewine <lhongxu@outlook.com> | 2023-03-22 00:09:05 +0800 |
commit | dec6a6d91a07e8c16f2c83b7ff7af8d3cf81aaea (patch) | |
tree | 3acf3c1f2637f1ad77b670fba90bff35867de8a8 /pkgs/desktops/deepin | |
parent | 08e3ef6f79c72e92bbfa996ee83e5137707c49bc (diff) |
deepin.deepin-clone: init at 5.0.11
Diffstat (limited to 'pkgs/desktops/deepin')
-rw-r--r-- | pkgs/desktops/deepin/apps/deepin-clone/default.nix | 77 | ||||
-rw-r--r-- | pkgs/desktops/deepin/default.nix | 1 |
2 files changed, 78 insertions, 0 deletions
diff --git a/pkgs/desktops/deepin/apps/deepin-clone/default.nix b/pkgs/desktops/deepin/apps/deepin-clone/default.nix new file mode 100644 index 0000000000000..9252224488ee1 --- /dev/null +++ b/pkgs/desktops/deepin/apps/deepin-clone/default.nix @@ -0,0 +1,77 @@ +{ stdenv +, lib +, fetchFromGitHub +, cmake +, qttools +, pkg-config +, qtbase +, wrapQtAppsHook +, dtkwidget +, qt5integration +, qt5platform-plugins +, libuuid +, parted +, partclone +}: + +stdenv.mkDerivation rec { + pname = "deepin-clone"; + version = "5.0.11"; + + src = fetchFromGitHub { + owner = "linuxdeepin"; + repo = pname; + rev = version; + sha256 = "sha256-ZOJc8R82R9q87Qpf/J4CXE+xL6nvbsXRIs0boNY+2uk="; + }; + + postPatch = '' + substituteInPlace app/{deepin-clone-ionice,deepin-clone-pkexec,deepin-clone.desktop,com.deepin.pkexec.deepin-clone.policy.tmp} \ + --replace "/usr" "$out" + + substituteInPlace app/src/corelib/ddevicediskinfo.cpp \ + --replace "/sbin/blkid" "${libuuid}/bin/blkid" + + substituteInPlace app/src/corelib/helper.cpp \ + --replace "/bin/lsblk" "${libuuid}/bin/lsblk" \ + --replace "/sbin/sfdisk" "${libuuid}/bin/sfdisk" \ + --replace "/sbin/partprobe" "${parted}/bin/partprobe" \ + --replace "/usr/sbin" "${partclone}/bin" + ''; + + nativeBuildInputs = [ + cmake + qttools + pkg-config + wrapQtAppsHook + ]; + + buildInputs = [ + qtbase + dtkwidget + qt5platform-plugins + libuuid + parted + partclone + ]; + + cmakeFlags = [ + "-DDISABLE_DFM_PLUGIN=YES" + ]; + + strictDeps = true; + + # qt5integration must be placed before qtsvg in QT_PLUGIN_PATH + qtWrapperArgs = [ + "--prefix QT_PLUGIN_PATH : ${qt5integration}/${qtbase.qtPluginPrefix}" + ]; + + meta = with lib; { + description = "Disk and partition backup/restore tool"; + homepage = "https://github.com/linuxdeepin/deepin-clone"; + license = licenses.gpl3Plus; + platforms = platforms.linux; + maintainers = teams.deepin.members; + }; +} + diff --git a/pkgs/desktops/deepin/default.nix b/pkgs/desktops/deepin/default.nix index 96c3d08b65dc7..1c3d8db8a026d 100644 --- a/pkgs/desktops/deepin/default.nix +++ b/pkgs/desktops/deepin/default.nix @@ -39,6 +39,7 @@ let deepin-calculator = callPackage ./apps/deepin-calculator { }; deepin-camera = callPackage ./apps/deepin-camera { }; deepin-compressor = callPackage ./apps/deepin-compressor { }; + deepin-clone = callPackage ./apps/deepin-clone { }; deepin-draw = callPackage ./apps/deepin-draw { }; deepin-editor = callPackage ./apps/deepin-editor { }; deepin-image-viewer = callPackage ./apps/deepin-image-viewer { }; |