blob: d6e76af14d66ca2d136ed9473b770014be4e5a9a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
{ lib
, stdenv
, fetchFromGitHub
, cmake
, extra-cmake-modules
, fcitx5
, qtbase
, qtwayland
, wrapQtAppsHook
, wayland
}:
let
majorVersion = lib.versions.major qtbase.version;
in
stdenv.mkDerivation rec {
pname = "fcitx5-qt${majorVersion}";
version = "5.1.6";
src = fetchFromGitHub {
owner = "fcitx";
repo = "fcitx5-qt";
rev = version;
hash = "sha256-ptAJNc7zhXQ+nFfjmVQd5nZvN5lyk0jV6AHBKQkUGOM=";
};
postPatch = ''
substituteInPlace qt${majorVersion}/platforminputcontext/CMakeLists.txt \
--replace \$"{CMAKE_INSTALL_QT${majorVersion}PLUGINDIR}" $out/${qtbase.qtPluginPrefix}
'';
cmakeFlags = [
"-DENABLE_QT4=OFF"
"-DENABLE_QT5=OFF"
"-DENABLE_QT6=OFF"
"-DENABLE_QT${majorVersion}=ON"
];
nativeBuildInputs = [
cmake
extra-cmake-modules
wrapQtAppsHook
];
buildInputs = [
qtbase
qtwayland
fcitx5
wayland
];
meta = with lib; {
description = "Fcitx5 Qt Library";
homepage = "https://github.com/fcitx/fcitx5-qt";
license = with licenses; [ lgpl21Plus bsd3 ];
maintainers = with maintainers; [ poscat ];
platforms = platforms.linux;
};
}
|