nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 mkDerivation,
3 lib,
4 fetchFromGitHub,
5
6 anthy,
7 hunspell,
8 libchewing,
9 libpinyin,
10 maliit-framework,
11 qtfeedback,
12 qtmultimedia,
13 qtquickcontrols2,
14 qtgraphicaleffects,
15
16 cmake,
17 pkg-config,
18 wrapGAppsHook3,
19}:
20
21mkDerivation {
22 pname = "maliit-keyboard";
23 version = "2.3.1-unstable-2024-09-04";
24
25 src = fetchFromGitHub {
26 owner = "maliit";
27 repo = "keyboard";
28 rev = "cbb0bbfa67354df76c25dbc3b1ea99a376fd15bb";
29 sha256 = "sha256-6ITlV/RJkPDrnsFyeWYWaRTYTaY6NAbHDqpUZGGKyi4=";
30 };
31
32 postPatch = ''
33 substituteInPlace data/schemas/org.maliit.keyboard.maliit.gschema.xml \
34 --replace /usr/share "$out/share"
35 '';
36
37 buildInputs = [
38 anthy
39 hunspell
40 libchewing
41 libpinyin
42 maliit-framework
43 qtfeedback
44 qtmultimedia
45 qtquickcontrols2
46 qtgraphicaleffects
47 ];
48
49 cmakeFlags = [
50 "-DCMAKE_INSTALL_PREFIX=${placeholder "out"}"
51 "-DCMAKE_INSTALL_LIBDIR=lib"
52 ];
53
54 nativeBuildInputs = [
55 cmake
56 pkg-config
57 wrapGAppsHook3
58 ];
59
60 postInstall = ''
61 glib-compile-schemas "$out"/share/glib-2.0/schemas
62 '';
63
64 meta = with lib; {
65 description = "Virtual keyboard";
66 mainProgram = "maliit-keyboard";
67 homepage = "http://maliit.github.io/";
68 license = with licenses; [
69 lgpl3Only
70 bsd3
71 cc-by-30
72 ];
73 maintainers = [ ];
74 };
75}