diff --git a/app-i18n/anthy-unicode/Manifest b/app-i18n/anthy-unicode/Manifest new file mode 100644 index 0000000000000..9c54e3ea05da2 --- /dev/null +++ b/app-i18n/anthy-unicode/Manifest @@ -0,0 +1 @@ +DIST anthy-unicode-1.0.0.20260213.tar.xz 3482244 BLAKE2B 4d1eae4c18951452d26577e2477fc4cfb645ba362aa37ed9bc8e16c3ac3852c3409325ebbaad01898ddf65d8af208d3559fbe06e469a11e7b68567cf83ed5212 SHA512 895d7f325214ae2174eafed98d3de466d59dd26b58e3220670c804078b94b718ab4a634bf5daddb9f6a0b13ffb9a132460f65ef512fa0af5e08077f85d84227e diff --git a/app-i18n/anthy-unicode/anthy-unicode-1.0.0.20260213.ebuild b/app-i18n/anthy-unicode/anthy-unicode-1.0.0.20260213.ebuild new file mode 100644 index 0000000000000..7de900db0cfdf --- /dev/null +++ b/app-i18n/anthy-unicode/anthy-unicode-1.0.0.20260213.ebuild @@ -0,0 +1,74 @@ +# Copyright 2026 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit meson elisp-common + +DESCRIPTION="Another Anthy - Japanese character set input library for Unicode" +HOMEPAGE="https://github.com/fujiwarat/anthy-unicode" +SRC_URI="https://github.com/fujiwarat/anthy-unicode/releases/download/${PV}/${P}.tar.xz" + +# GPL-2+ for dictionaries +LICENSE="GPL-2+ LGPL-2.1+" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86" +IUSE="emacs" + +DEPEND="emacs? ( app-editors/emacs:* )" +RDEPEND="${DEPEND}" + +SITEFILE="50${PN}-gentoo.el" + +src_configure() { + local emesonargs=( + -Demacs_path="$(usev emacs ${EMACS})" + -Dlisp_dir="$(usev emacs ${SITELISP})" + $(meson_feature emacs) + ) + meson_src_configure +} + +src_install() { + meson_src_install + + rm doc/Makefile* || die + dodoc -r doc + + if use emacs; then + elisp-site-file-install "${FILESDIR}"/${SITEFILE} + else + rm -r "${ED}"/usr/share/emacs || die + fi +} + +pkg_preinst() { + if ! has_version app-i18n/anthy-unicode; then + show_migrate_warning=true + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen + + if [[ -n ${show_migrate_warning} ]]; then + ewarn "The path of the private dictionary has changed with anthy-unicode:" + ewarn "app-i18n/anthy: ~/.anthy" + ewarn "app-i18n/anthy-unicode: ~/.config/anthy" + ewarn " " + ewarn "To migrate the private dictionary, launch:" + ewarn "anthy-dic-tool-unicode --migrate" + ewarn " " + ewarn "To make sure you only use anthy-unicode, please update all installed anthy's packages:" + has_version " + + + + cjk@gentoo.org + Cjk + + + Anthy Unicode is another Anthy project and provides the library to input + Japanese on the applications. + This ebuild includes cannadic as a server-side dictionary, so you don't need + any extra package to run it. You can use anthy-unicode with + app-i18n/fcitx-anthy, app-i18n/uim (XIM, GTK+ immodule) + and app-editors/emacs (to enable Anthy support for emacs, build + this package with emacs USE flag). + + + fujiwarat/anthy-unicode + +