2021-01-25 08:26:54 +00:00
|
|
|
{
|
|
|
|
lib,
|
2024-03-01 16:10:27 +00:00
|
|
|
stdenv,
|
2020-12-13 03:14:54 +00:00
|
|
|
fetchFromGitHub,
|
|
|
|
cmake,
|
|
|
|
extra-cmake-modules,
|
2024-03-01 16:10:27 +00:00
|
|
|
pkg-config,
|
2020-12-13 03:14:54 +00:00
|
|
|
fcitx5,
|
|
|
|
fcitx5-qt,
|
2024-03-01 16:10:27 +00:00
|
|
|
qtbase,
|
|
|
|
qtsvg,
|
|
|
|
qtwayland,
|
|
|
|
qtdeclarative,
|
|
|
|
qtx11extras ? null,
|
|
|
|
kitemviews,
|
2020-12-13 03:14:54 +00:00
|
|
|
kwidgetsaddons,
|
2024-03-01 16:10:27 +00:00
|
|
|
qtquickcontrols2 ? null,
|
|
|
|
kcoreaddons,
|
2020-12-13 03:14:54 +00:00
|
|
|
kdeclarative,
|
2024-03-01 16:10:27 +00:00
|
|
|
kirigami ? null,
|
|
|
|
kirigami2 ? null,
|
2020-12-13 03:14:54 +00:00
|
|
|
isocodes,
|
|
|
|
xkeyboardconfig,
|
|
|
|
libxkbfile,
|
2024-03-01 16:10:27 +00:00
|
|
|
libplasma ? null,
|
|
|
|
plasma-framework ? null,
|
|
|
|
wrapQtAppsHook,
|
2020-12-13 03:14:54 +00:00
|
|
|
kcmSupport ? true,
|
|
|
|
}:
|
|
|
|
|
2024-03-01 16:10:27 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2020-12-13 03:14:54 +00:00
|
|
|
pname = "fcitx5-configtool";
|
2024-10-09 00:34:26 +00:00
|
|
|
version = "5.1.7";
|
2020-12-13 03:14:54 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fcitx";
|
2021-06-02 12:42:16 +00:00
|
|
|
repo = pname;
|
2020-12-13 03:14:54 +00:00
|
|
|
rev = version;
|
2024-10-09 00:34:26 +00:00
|
|
|
hash = "sha256-6Slh1uZglRNBLQ1ziKf2xaP+NK6Abug/6TZcYy2HFPQ=";
|
2020-12-13 03:14:54 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
cmakeFlags = [
|
2024-03-01 16:10:27 +00:00
|
|
|
(lib.cmakeBool "KDE_INSTALL_USE_QT_SYS_PATHS" true)
|
|
|
|
(lib.cmakeBool "ENABLE_KCM" kcmSupport)
|
|
|
|
(lib.cmakeBool "USE_QT6" (lib.versions.major qtbase.version == "6"))
|
2020-12-13 03:14:54 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
extra-cmake-modules
|
2024-03-01 16:10:27 +00:00
|
|
|
pkg-config
|
|
|
|
wrapQtAppsHook
|
2020-12-13 03:14:54 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs =
|
|
|
|
[
|
|
|
|
fcitx5
|
|
|
|
fcitx5-qt
|
2024-03-01 16:10:27 +00:00
|
|
|
qtbase
|
|
|
|
qtsvg
|
|
|
|
qtwayland
|
|
|
|
kitemviews
|
|
|
|
kwidgetsaddons
|
2020-12-13 03:14:54 +00:00
|
|
|
isocodes
|
|
|
|
xkeyboardconfig
|
|
|
|
libxkbfile
|
2024-03-01 16:10:27 +00:00
|
|
|
]
|
|
|
|
++ lib.optionals (lib.versions.major qtbase.version == "5") [
|
|
|
|
qtx11extras
|
|
|
|
]
|
|
|
|
++ lib.optionals kcmSupport (
|
|
|
|
[
|
|
|
|
qtdeclarative
|
|
|
|
kcoreaddons
|
2020-12-13 03:14:54 +00:00
|
|
|
kdeclarative
|
2024-03-01 16:10:27 +00:00
|
|
|
]
|
|
|
|
++ lib.optionals (lib.versions.major qtbase.version == "5") [
|
|
|
|
qtquickcontrols2
|
2022-07-11 13:47:36 +00:00
|
|
|
plasma-framework
|
2024-03-01 16:10:27 +00:00
|
|
|
kirigami2
|
|
|
|
]
|
|
|
|
++ lib.optionals (lib.versions.major qtbase.version == "6") [
|
|
|
|
libplasma
|
|
|
|
kirigami
|
|
|
|
]
|
|
|
|
);
|
2020-12-13 03:14:54 +00:00
|
|
|
|
2021-01-15 09:19:50 +00:00
|
|
|
meta = with lib; {
|
2020-12-13 03:14:54 +00:00
|
|
|
description = "Configuration Tool for Fcitx5";
|
|
|
|
homepage = "https://github.com/fcitx/fcitx5-configtool";
|
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
maintainers = with maintainers; [ poscat ];
|
|
|
|
platforms = platforms.linux;
|
2022-12-15 05:36:35 +00:00
|
|
|
mainProgram = "fcitx5-config-qt";
|
2020-12-13 03:14:54 +00:00
|
|
|
};
|
|
|
|
}
|