Files
gentoo-zh/app-dicts/fcitx-pinyin-moegirl/fcitx-pinyin-moegirl-20260412.ebuild
T
Zakk dcd5752fc6 */*: correct LICENSE declarations that did not match upstream
因为对全部软件包逐一核对上游后发现 42 个的 `LICENSE=` 与上游实际授权不符,所以按上游的授权文件与源码文件头改正,并为其中被误标为开源、实为专有的软件补上
`RESTRICT`。

最严重的一类是专有软件被标成开源:`deepin-wine-helper` 与 `deepin-wine-plugin` 的 deb 内 copyright 写着
`All rights reserved by Wuhan Deepin Technology Co., Ltd.`,`app-misc/z-library` 的 deb
control 写 `License: unknown`,`media-sound/qqmusic` 用的 `CC0-1.0` 是公共领域捐弃、与腾讯的服务协议完全相反。

`net-proxy/clash-rs` 此前只有 `LICENSE+=`、没有基底 `LICENSE=`,主程序的 Apache-2.0 完全没有声明。

`sys-kernel/xanmod-sources` 的 `LICENSE+=" CDDL"` 在 xanmod patch 与 genpatches
中都找不到依据,一并删除。

Signed-off-by: Zakk <zakk@gentoozh.org>
2026-08-02 04:20:36 +10:00

61 lines
1.5 KiB
Bash

# Copyright 1999-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{12..14} )
inherit python-any-r1
DESCRIPTION="Fcitx 5 Pinyin Dictionary from zh.moegirl.org.cn"
HOMEPAGE="https://github.com/outloudvi/mw2fcitx"
SRC_URI="
https://github.com/outloudvi/mw2fcitx/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz
https://github.com/outloudvi/mw2fcitx/releases/download/${PV}/titles.txt -> ${P}-titles.txt
"
S="${WORKDIR}/mw2fcitx-${PV}"
LICENSE="MIT CC-BY-NC-SA-3.0"
SLOT="5"
KEYWORDS="~amd64"
IUSE="+fcitx rime"
REQUIRED_USE="|| ( fcitx rime )"
RDEPEND="
fcitx? ( app-i18n/fcitx:5 )
rime? ( || ( app-i18n/ibus-rime app-i18n/fcitx-rime ) )
"
BDEPEND="
${PYTHON_DEPS}
fcitx? ( app-i18n/libime:5 )
$(python_gen_any_dep '
dev-python/mw2fcitx[${PYTHON_SINGLE_USEDEP}]
')
"
python_check_deps() {
python_has_version "dev-python/mw2fcitx[${PYTHON_SINGLE_USEDEP}]"
}
src_compile() {
cp "${DISTDIR}/${P}-titles.txt" "${S}/titles.txt" || die
use fcitx && (mw2fcitx -c "${FILESDIR}/moegirl_dict_fcitx.py" || die)
use rime && (mw2fcitx -c "${FILESDIR}/moegirl_dict_rime.py" || die)
}
src_install() {
if use fcitx; then
DICT_PATH="/usr/share/fcitx5/pinyin/dictionaries"
insinto "${DICT_PATH}"
doins moegirl.dict
fperms 0644 "${DICT_PATH}/moegirl.dict"
fi
if use rime; then
DICT_PATH="/usr/share/rime-data"
insinto "${DICT_PATH}"
doins moegirl.dict.yaml
fperms 0644 "${DICT_PATH}/moegirl.dict.yaml"
fi
}