depot/third_party/nixpkgs/pkgs/desktops/deepin/library/dtkgui/default.nix
Default email 587713944a Project import generated by Copybara.
GitOrigin-RevId: 6143fc5eeb9c4f00163267708e26191d1e918932
2024-04-21 17:54:59 +02:00

74 lines
1.4 KiB
Nix

{ stdenv
, lib
, fetchFromGitHub
, pkg-config
, cmake
, qttools
, doxygen
, wrapQtAppsHook
, qtbase
, dtkcore
, qtimageformats
, lxqt
, librsvg
}:
stdenv.mkDerivation rec {
pname = "dtkgui";
version = "5.6.22";
src = fetchFromGitHub {
owner = "linuxdeepin";
repo = pname;
rev = version;
hash = "sha256-h3DFG6FaJXP9o9u8R31MtX3Z1+P3DrNDT8Xbd8tlI4Y=";
};
patches = [
./fix-pkgconfig-path.patch
./fix-pri-path.patch
];
nativeBuildInputs = [
cmake
qttools
doxygen
pkg-config
wrapQtAppsHook
];
buildInputs = [
qtbase
lxqt.libqtxdg
librsvg
];
propagatedBuildInputs = [
dtkcore
qtimageformats
];
cmakeFlags = [
"-DDTK_VERSION=${version}"
"-DBUILD_DOCS=ON"
"-DMKSPECS_INSTALL_DIR=${placeholder "out"}/mkspecs/modules"
"-DQCH_INSTALL_DESTINATION=${placeholder "doc"}/${qtbase.qtDocPrefix}"
"-DCMAKE_INSTALL_LIBEXECDIR=${placeholder "dev"}/libexec"
];
preConfigure = ''
# qt.qpa.plugin: Could not find the Qt platform plugin "minimal"
# A workaround is to set QT_PLUGIN_PATH explicitly
export QT_PLUGIN_PATH=${qtbase.bin}/${qtbase.qtPluginPrefix}
'';
outputs = [ "out" "dev" "doc" ];
meta = with lib; {
description = "Deepin Toolkit, gui module for DDE look and feel";
homepage = "https://github.com/linuxdeepin/dtkgui";
license = licenses.lgpl3Plus;
platforms = platforms.linux;
maintainers = teams.deepin.members;
};
}