diff options
author | Vladimír Čunát <v@cunat.cz> | 2019-09-04 11:00:56 +0200 |
---|---|---|
committer | Vladimír Čunát <v@cunat.cz> | 2019-09-04 11:00:56 +0200 |
commit | 4aad2947f8d680f18e5b01e115cf8cff22186998 (patch) | |
tree | a7a3d020efc6ec7be822bc06e08eca3ac311c9e2 /pkgs/tools/inputmethods/ibus-engines | |
parent | 2c5835b09a1d4966756212902d36b1b8ab242da6 (diff) | |
parent | 1d8a3973f46a2d1360f855eaa0f3a19859771793 (diff) | |
download | nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar.gz nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar.bz2 nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar.lz nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar.xz nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.tar.zst nixpkgs-4aad2947f8d680f18e5b01e115cf8cff22186998.zip |
Merge branch 'master' into staging-next
Diffstat (limited to 'pkgs/tools/inputmethods/ibus-engines')
-rw-r--r-- | pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix | 46 | ||||
-rw-r--r-- | pkgs/tools/inputmethods/ibus-engines/ibus-hangul/fix-paths.patch | 13 |
2 files changed, 49 insertions, 10 deletions
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix index 3b8b3489a1d..0a38ccfa3bd 100644 --- a/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix +++ b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix @@ -1,5 +1,13 @@ -{ stdenv, fetchurl, intltool, pkgconfig -, gtk3, ibus, libhangul, python3 +{ stdenv +, fetchurl +, substituteAll +, intltool +, pkgconfig +, wrapGAppsHook +, gtk3 +, ibus +, libhangul +, python3 }: stdenv.mkDerivation rec { @@ -11,18 +19,36 @@ stdenv.mkDerivation rec { sha256 = "0gha8dfdf54rx8fv3yfikbgdg6lqq6l883lhg7q68ybvkjx9bwbs"; }; - buildInputs = [ gtk3 ibus libhangul python3 ]; + patches = [ + (substituteAll { + src = ./fix-paths.patch; + libhangul = "${libhangul}/lib/libhangul.so.1"; + }) + ]; - nativeBuildInputs = [ intltool pkgconfig python3.pkgs.wrapPython ]; + nativeBuildInputs = [ + intltool + pkgconfig + python3.pkgs.wrapPython + wrapGAppsHook + ]; - postFixup = "wrapPythonPrograms"; + buildInputs = [ + gtk3 + ibus + libhangul + (python3.withPackages (pypkgs: with pypkgs; [ + pygobject3 + (toPythonModule ibus) + ])) + ]; meta = with stdenv.lib; { isIbusEngine = true; - description = "Ibus Hangul engine"; - homepage = https://github.com/choehwanjin/ibus-hangul; - license = licenses.gpl2; - platforms = platforms.linux; - maintainers = with maintainers; [ ericsagnes ]; + description = "Ibus Hangul engine"; + homepage = https://github.com/choehwanjin/ibus-hangul; + license = licenses.gpl2; + maintainers = with maintainers; [ ericsagnes ]; + platforms = platforms.linux; }; } diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/fix-paths.patch b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/fix-paths.patch new file mode 100644 index 00000000000..7487d074d55 --- /dev/null +++ b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/fix-paths.patch @@ -0,0 +1,13 @@ +diff --git a/setup/main.py b/setup/main.py +index 8d581cd..2ac47b9 100644 +--- a/setup/main.py ++++ b/setup/main.py +@@ -37,7 +37,7 @@ + + def get_hangul_keyboard_list(): + from ctypes import CDLL, c_int, c_char_p +- libhangul = CDLL('libhangul.so.1') ++ libhangul = CDLL('@libhangul@') + libhangul.hangul_ic_get_n_keyboards.argtypes = [] + libhangul.hangul_ic_get_n_keyboards.restype = c_int + libhangul.hangul_ic_get_keyboard_id.argtypes = [c_int] |