Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 85 lines 1.4 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 cmake, 6 extra-cmake-modules, 7 fcitx5, 8 gobject-introspection, 9 glib, 10 gtk2, 11 gtk3, 12 gtk4, 13 fmt, 14 pcre, 15 libuuid, 16 libselinux, 17 libsepol, 18 libthai, 19 libdatrie, 20 libXdmcp, 21 libxkbcommon, 22 libepoxy, 23 dbus, 24 at-spi2-core, 25 libXtst, 26 withGTK2 ? false, 27}: 28 29stdenv.mkDerivation rec { 30 pname = "fcitx5-gtk"; 31 version = "5.1.4"; 32 33 src = fetchFromGitHub { 34 owner = "fcitx"; 35 repo = pname; 36 rev = version; 37 hash = "sha256-MlBLhgqpF+A9hotnhX83349wIpCQfzsqpyZb0xME2XQ="; 38 }; 39 40 outputs = [ 41 "out" 42 "dev" 43 ]; 44 45 cmakeFlags = [ 46 "-DGOBJECT_INTROSPECTION_GIRDIR=share/gir-1.0" 47 "-DGOBJECT_INTROSPECTION_TYPELIBDIR=lib/girepository-1.0" 48 ] 49 ++ lib.optional (!withGTK2) "-DENABLE_GTK2_IM_MODULE=off"; 50 51 buildInputs = [ 52 glib 53 gtk3 54 gtk4 55 fmt 56 fcitx5 57 pcre 58 libuuid 59 libselinux 60 libsepol 61 libthai 62 libdatrie 63 libXdmcp 64 libxkbcommon 65 libepoxy 66 dbus 67 at-spi2-core 68 libXtst 69 ] 70 ++ lib.optional withGTK2 gtk2; 71 72 nativeBuildInputs = [ 73 cmake 74 extra-cmake-modules 75 gobject-introspection 76 ]; 77 78 meta = with lib; { 79 description = "Fcitx5 gtk im module and glib based dbus client library"; 80 homepage = "https://github.com/fcitx/fcitx5-gtk"; 81 license = licenses.lgpl21Plus; 82 maintainers = with maintainers; [ poscat ]; 83 platforms = platforms.linux; 84 }; 85}