Created
May 24, 2020 09:33
-
-
Save trickart/99ea9b7f405d82638f49a33ca7503427 to your computer and use it in GitHub Desktop.
fcitx-mozc-neologd-utにカタカナ変換を追加するパッチ。あまりに適当な追加方法なのでAURには上げずにこちらにメモ
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- PKGBUILD.org 2020-05-24 18:31:00.821773595 +0900 | |
+++ PKGBUILD 2020-05-24 02:49:29.631425029 +0900 | |
@@ -9,6 +9,7 @@ | |
_mozcver=2.23.2815.102 | |
_fcitxver=2.23.2815.102.1 | |
_neologddate=20200514 | |
+_neologdrel=1 | |
pkgver=${_mozcver}.${_neologddate} | |
pkgrel=1 | |
@@ -28,7 +29,10 @@ | |
add_support_new_japanese_era.patch::https://salsa.debian.org/debian/mozc/raw/master/debian/patches/add_support_new_japanese_era.patch | |
https://download.fcitx-im.org/fcitx-mozc/fcitx-mozc-${_fcitxver}.patch | |
https://download.fcitx-im.org/fcitx-mozc/fcitx-mozc-icon.tar.gz | |
- "https://osdn.net/frs/chamber_redir.php?m=jaist&f=%2Fusers%2F26%2F26401%2Fmozcdic-neologd-ut-20200514.1.tar.bz2" | |
+ https://osdn.net/users/trickart/pf/trickart_pkgbuild/dl/mozc-neologd-ut/mozcdic-neologd-ut-${_neologddate}.${_neologdrel}.tar.bz2 | |
+ generate-katakana-english-entries.rb | |
+ split-new-words-and-add-id.rb | |
+ id.def | |
) | |
sha1sums=( | |
@@ -40,6 +44,9 @@ | |
'63a2b10e7d209c6216e2d912b2629efc44c637ea' | |
'883f4fc489a9ed1c07d2d2ec37ca72509f04ea5d' | |
'SKIP' | |
+ '1defa218cd5d6d587aed2cccd72b4341af7ab3ef' | |
+ 'ca3f139560b79a5bfd9ebe68d48f50270bbde04a' | |
+ '24d39baf52e36bc54ab82fb7bf667d4060bdba64' | |
) | |
prepare() { | |
@@ -50,6 +57,15 @@ | |
patch -Np1 -i ${srcdir}/fcitx-mozc-${_fcitxver}.patch | |
mkdir -p src/third_party/ | |
cp -a ${srcdir}/japanese_usage_dictionary src/third_party/ | |
+ | |
+ wget -N http://ftp.monash.edu/pub/nihongo/edict2u.gz | |
+ gzip -dk edict2u.gz | |
+ ruby -EUTF-8 ../generate-katakana-english-entries.rb edict2u | |
+ mkdir -p ../src | |
+ cp ${srcdir}/id.def ../src/id.def | |
+ ruby -EUTF-8 ../split-new-words-and-add-id.rb edict2u.kanaeng | |
+ cat edict2u.kanaeng.new >> src/data/dictionary_oss/dictionary00.txt | |
+ | |
cat ${srcdir}/mozcdic-neologd-ut-${_neologddate}.${pkgrel}/mozcdic-*-ut-*.txt >> src/data/dictionary_oss/dictionary00.txt | |
} | |
@@ -60,7 +76,6 @@ | |
rm -rf unix/fcitx5/ | |
_targets="server/server.gyp:mozc_server gui/gui.gyp:mozc_tool renderer/renderer.gyp:mozc_renderer unix/fcitx/fcitx.gyp:fcitx-mozc unix/fcitx/fcitx.gyp:gen_fcitx_mozc_i18n" | |
- | |
GYP_DEFINES="use_libprotobuf=1 use_libzinnia=1 document_dir=/usr/share/licenses/mozc" python build_mozc.py gyp --gypdir=/usr/bin --target_platform=Linux | |
python build_mozc.py build -c $_bldtype $_targets | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment