summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org>2019-12-23 21:18:36 +0000
committerMike Gilbert <floppym@gentoo.org>2019-12-29 14:31:34 -0500
commitd149e41c89b85dff47bd5cdc332e6c0817acdd72 (patch)
treea8544db65eba76f44b0d8e5452f849a5f08278f6 /app-i18n/librime/librime-1.5.3-r1.ebuild
parentapp-i18n/librime: Add "debug" USE flag. (diff)
downloadgentoo-d149e41c89b85dff47bd5cdc332e6c0817acdd72.tar.gz
gentoo-d149e41c89b85dff47bd5cdc332e6c0817acdd72.tar.bz2
gentoo-d149e41c89b85dff47bd5cdc332e6c0817acdd72.zip
app-i18n/librime: Set secure mode of log files.
Bug: https://bugs.gentoo.org/695702 Signed-off-by: Arfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org> Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'app-i18n/librime/librime-1.5.3-r1.ebuild')
-rw-r--r--app-i18n/librime/librime-1.5.3-r1.ebuild74
1 files changed, 74 insertions, 0 deletions
diff --git a/app-i18n/librime/librime-1.5.3-r1.ebuild b/app-i18n/librime/librime-1.5.3-r1.ebuild
new file mode 100644
index 000000000000..b41cd0ea4399
--- /dev/null
+++ b/app-i18n/librime/librime-1.5.3-r1.ebuild
@@ -0,0 +1,74 @@
+# Copyright 2012-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+inherit cmake-utils
+
+if [[ "${PV}" == "9999" ]]; then
+ inherit git-r3
+
+ EGIT_REPO_URI="https://github.com/rime/librime"
+ EGIT_SUBMODULES=()
+fi
+
+DESCRIPTION="RIME (Rime Input Method Engine) core library"
+HOMEPAGE="https://rime.im/ https://github.com/rime/librime"
+if [[ "${PV}" == "9999" ]]; then
+ SRC_URI=""
+else
+ SRC_URI="https://github.com/rime/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+fi
+
+LICENSE="BSD"
+SLOT="0/1"
+KEYWORDS="~amd64 ~arm64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug test"
+RESTRICT="!test? ( test )"
+
+BDEPEND=""
+RDEPEND="app-i18n/opencc:0=
+ >=dev-cpp/glog-0.3.5:0=
+ dev-cpp/yaml-cpp:0=
+ dev-libs/boost:0=[nls,threads]
+ dev-libs/leveldb:0=
+ dev-libs/marisa:0="
+DEPEND="${RDEPEND}
+ dev-libs/darts
+ dev-libs/utfcpp
+ x11-base/xorg-proto
+ test? ( dev-cpp/gtest )"
+
+PATCHES=(
+ "${FILESDIR}/${P}-log_files_mode.patch"
+)
+
+DOCS=(CHANGELOG.md README.md)
+
+src_prepare() {
+ # Use headers of dev-libs/darts, dev-libs/utfcpp and x11-base/xorg-proto.
+ sed -e "/\${PROJECT_SOURCE_DIR}\/thirdparty/d" -i CMakeLists.txt || die
+ rm -r thirdparty || die
+
+ cmake-utils_src_prepare
+}
+
+src_configure() {
+ local -x CXXFLAGS="${CXXFLAGS} -I${ESYSROOT}/usr/include/utf8cpp"
+
+ if use debug; then
+ CXXFLAGS+=" -DDCHECK_ALWAYS_ON"
+ else
+ CXXFLAGS+=" -DNDEBUG"
+ fi
+
+ local mycmakeargs=(
+ -DBOOST_USE_CXX11=ON
+ -DBUILD_TEST=$(usex test ON OFF)
+ -DCMAKE_DISABLE_FIND_PACKAGE_Gflags=ON
+ -DCMAKE_DISABLE_FIND_PACKAGE_Iconv=ON
+ -DLIB_INSTALL_DIR="${EPREFIX}/usr/$(get_libdir)"
+ )
+
+ cmake-utils_src_configure
+}