10 qtx11extras ? null, # Qt 5 only
22 isQt5 = lib.versionOlder qtbase.version "6";
24 stdenv.mkDerivation (finalAttrs: {
25 pname = "qtstyleplugin-kvantum${lib.optionalString isQt5 "5"}";
28 src = fetchFromGitHub {
31 rev = "V${finalAttrs.version}";
32 hash = "sha256-x2XsJ26y9y6IF9aY0fmAcvO4zmwLjvE2Lfvzw+GqchM=";
49 ++ lib.optionals isQt5 [ qtx11extras ]
50 ++ lib.optionals (!isQt5) [
55 sourceRoot = "${finalAttrs.src.name}/Kvantum";
59 # add xdg dirs support
60 url = "https://github.com/tsujan/Kvantum/commit/01989083f9ee75a013c2654e760efd0a1dea4a68.patch";
61 hash = "sha256-HPx+p4Iek/Me78olty1fA0dUNceK7bwOlTYIcQu8ycc=";
67 substituteInPlace style/CMakeLists.txt \
68 --replace-fail '"''${_Qt6_PLUGIN_INSTALL_DIR}/' "\"$out/$qtPluginPrefix/" \
69 --replace-fail '"''${_Qt5_PLUGIN_INSTALL_DIR}/' "\"$out/$qtPluginPrefix/"
73 (lib.cmakeBool "ENABLE_QT5" isQt5)
76 postInstall = lib.optionalString isQt5 ''
77 # make default Kvantum themes available for Qt 5 apps
79 ln -s "${qt6Kvantum}/share/Kvantum" "$out/share/Kvantum"
82 passthru.updateScript = gitUpdater {
87 description = "SVG-based Qt5 theme engine plus a config tool and extra themes";
88 homepage = "https://github.com/tsujan/Kvantum";
89 license = lib.licenses.gpl3Plus;
90 platforms = lib.platforms.linux;
91 maintainers = with lib.maintainers; [