depot/pkgs/desktops/deepin/apps/deepin-picker/default.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

57 lines
1.2 KiB
Nix

{
stdenv,
lib,
fetchFromGitHub,
pkg-config,
libsForQt5,
dtkwidget,
xorg,
}:
stdenv.mkDerivation rec {
pname = "deepin-picker";
version = "6.0.1";
src = fetchFromGitHub {
owner = "linuxdeepin";
repo = pname;
rev = version;
hash = "sha256-vChSlP+lGufurvLkYbljAhc8qqqbc1bxQ2UIROreK2o=";
};
nativeBuildInputs = [
libsForQt5.qmake
libsForQt5.qttools
pkg-config
libsForQt5.wrapQtAppsHook
];
buildInputs = [
libsForQt5.qtbase
dtkwidget
libsForQt5.qtsvg
xorg.libXtst
];
postPatch = ''
substituteInPlace com.deepin.Picker.service \
--replace "/usr/bin/deepin-picker" "$out/bin/deepin-picker"
'';
qmakeFlags = [
"BINDIR=${placeholder "out"}/bin"
"ICONDIR=${placeholder "out"}/share/icons/hicolor/scalable/apps"
"APPDIR=${placeholder "out"}/share/applications"
"DSRDIR=${placeholder "out"}/share/deepin-picker"
"DOCDIR=${placeholder "out"}/share/dman/deepin-picker"
];
meta = with lib; {
description = "Color picker application";
mainProgram = "deepin-picker";
homepage = "https://github.com/linuxdeepin/deepin-picker";
license = licenses.gpl3Plus;
platforms = platforms.linux;
maintainers = teams.deepin.members;
};
}