mirror of
https://github.com/gentoo-mirror/gentoo-zh.git
synced 2025-04-18 23:38:57 -04:00
fix libime build
This commit is contained in:
parent
83349554bc
commit
51bf4416b3
48
app-i18n/libime/files/libime-1.0.7-fix-compile-error.patch
Normal file
48
app-i18n/libime/files/libime-1.0.7-fix-compile-error.patch
Normal file
@ -0,0 +1,48 @@
|
||||
From 6b65eed26351a7186804d4885e8163be60be7cb6 Mon Sep 17 00:00:00 2001
|
||||
From: Weng Xuetian <wengxt@gmail.com>
|
||||
Date: Sun, 5 Sep 2021 10:46:58 -0700
|
||||
Subject: [PATCH] Add <cmath> to include.
|
||||
|
||||
Fix #25
|
||||
---
|
||||
src/libime/core/languagemodel.cpp | 1 +
|
||||
src/libime/core/userlanguagemodel.cpp | 1 +
|
||||
test/testhistorybigram.cpp | 1 +
|
||||
3 files changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/libime/core/languagemodel.cpp b/src/libime/core/languagemodel.cpp
|
||||
index 3706452..71b9a5c 100644
|
||||
--- a/src/libime/core/languagemodel.cpp
|
||||
+++ b/src/libime/core/languagemodel.cpp
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "constants.h"
|
||||
#include "lattice.h"
|
||||
#include "lm/model.hh"
|
||||
+#include <cmath>
|
||||
#include <fcitx-utils/fs.h>
|
||||
#include <fstream>
|
||||
#include <type_traits>
|
||||
diff --git a/src/libime/core/userlanguagemodel.cpp b/src/libime/core/userlanguagemodel.cpp
|
||||
index de19eb3..bfb228b 100644
|
||||
--- a/src/libime/core/userlanguagemodel.cpp
|
||||
+++ b/src/libime/core/userlanguagemodel.cpp
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "lm/model.hh"
|
||||
#include "utils.h"
|
||||
#include "utils_p.h"
|
||||
+#include <cmath>
|
||||
|
||||
namespace libime {
|
||||
|
||||
diff --git a/test/testhistorybigram.cpp b/test/testhistorybigram.cpp
|
||||
index 409eafc..1869c93 100644
|
||||
--- a/test/testhistorybigram.cpp
|
||||
+++ b/test/testhistorybigram.cpp
|
||||
@@ -6,6 +6,7 @@
|
||||
|
||||
#include "libime/core/historybigram.h"
|
||||
#include <boost/range/irange.hpp>
|
||||
+#include <cmath>
|
||||
#include <fcitx-utils/log.h>
|
||||
#include <sstream>
|
||||
|
@ -34,6 +34,10 @@ DEPEND="${RDEPEND}
|
||||
kde-frameworks/extra-cmake-modules:5
|
||||
virtual/pkgconfig"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/${P}-fix-compile-error.patch"
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
ln -s "${DISTDIR}/fcitx5-lm_sc.3gm.arpa-20140820.tar.bz2" data/lm_sc.3gm.arpa-20140820.tar.bz2 || die
|
||||
ln -s "${DISTDIR}/fcitx5-dict.utf8-20210402.tar.xz" data/dict.utf8-20210402.tar.xz || die
|
||||
|
Loading…
x
Reference in New Issue
Block a user