librime-sbxlm-git 编译过程
截止到 20220621
每次 boots 版本更新后,archlinux 上的声笔拼音就会挂,需要重新编译
aur 上面声笔拼音 librime-sbxlm 的脚本已经失效,需要简单修改,脚本维护者这几个月状态不好,有点忙不过来,大家理解万岁~
首先,下载 PKGBUILD 和 0001-fix-build.patch
git clone https://aur.archlinux.org/librime-sbxlm-git.git
修改 PKGBUILD 文件,将其中的 22 行的 git://github.com/sbxlmdsl/librime.git 改成 git+https://github.com/sbxlmdsl/librime.git
修改 0001-fix-build.patch ,删除 173~209 行或加#
@@ -233,30 +234,30 @@ namespace rime {
encoder_->Load(ticket);
}
}
-
+
static bool starts_with_completion(an<Translation> translation) {
if (!translation)
return false;
auto cand = translation->Peek();
return cand && cand->type() == "completion";
}
-
+
an<Translation> TableTranslator::Query(const string& input,
const Segment& segment) {
if (!segment.HasTag(tag_))
return nullptr;
DLOG(INFO) << "input = '" << input
<< "', [" << segment.start << ", " << segment.end << ")";
-
+
FinishSession();
-
+
bool enable_user_dict = user_dict_ && user_dict_->loaded() &&
!IsUserDictDisabledFor(input);
-
+
const string& preedit(input);
string code = input;
boost::trim_right_if(code, boost::is_any_of(delimiters_));
-
+
an<Translation> translation;
if (enable_completion_) {
translation = Cached<LazyTableTranslation>(
开始编译,建议最好走代理,整个过程大概几分钟,编译完成后要需要管理员密码安装 librime-sbxlm
makepkg -si
下次需要再次编译的时候,将目录下的 pkg.tar.zst 文件删除即可
2022-08-07 更新
上面的 PKGBUILD 和 patch 文件在 sbxlmdsl/librime(53ca3b7deb46d3915165a16aaf9a58490a4cbfec 版本) 编译通过