From 06972a4c51ba3ad21e816e3358bb420f1121d7d2 Mon Sep 17 00:00:00 2001 From: Feng Shu Date: Fri, 13 Jan 2023 08:39:04 +0800 Subject: gnu: Add emacs-liberime. * gnu/packages/emacs-xyz.scm (emacs-liberime): New variable. Signed-off-by: Nicolas Goaziou --- gnu/packages/emacs-xyz.scm | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 2b28680dbb..00df763fca 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -31363,6 +31363,47 @@ (define-public emacs-rime "Rime is an Emacs input method built upon Rime input method engine.") (license license:gpl3+))) +(define-public emacs-liberime + (let ((commit "cc9eb9812fd6f68e78ed6a0c0a85da7a18765753") + (revision "0") + (version "0.0.6")) + (package + (name "emacs-liberime") + (version (git-version (string-append "v" version) revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/merrickluo/liberime") + (commit commit))) + (sha256 + (base32 + "11c2wj00wwbdxqkzl60sd77cp43rja5v8hrvhrvhg75v62kawva2")) + (file-name (git-file-name name version)))) + (build-system emacs-build-system) + (arguments + (list + #:include #~(cons "^src/liberime-core.so$" %default-include) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'delete-files-and-patch-paths + (lambda* (#:key inputs #:allow-other-keys) + (delete-file-recursively "emacs-module") + (emacs-substitute-variables "liberime.el" + ("liberime-module-file" + (string-append #$output "/src/liberime-core.so")) + ("liberime-shared-data-dir" + (search-input-directory inputs "share/rime-data"))))) + (add-before 'install 'build-emacs-module + (lambda _ + (invoke "make")))))) + (inputs (list librime rime-data)) + (home-page "https://github.com/merrickluo/liberime") + (synopsis "Librime Emacs Lisp binding") + (description + "Liberime is an Emacs dynamic module provide librime bindings.") + (license license:gpl3+)))) + (define-public emacs-bison-mode (package (name "emacs-bison-mode") -- cgit v1.2.3