commit:     ddedb2650b0beb769a2e165681be5a99a46cfac8
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 27 21:34:23 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Tue Jul 27 21:54:09 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ddedb265

dev-libs/marisa: keyword 0.2.6 for ~riscv

Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 dev-libs/marisa/files/marisa-0.2.6-riscv_word_size.patch | 11 +++++++++++
 dev-libs/marisa/marisa-0.2.6.ebuild                      |  8 ++++++--
 2 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/dev-libs/marisa/files/marisa-0.2.6-riscv_word_size.patch 
b/dev-libs/marisa/files/marisa-0.2.6-riscv_word_size.patch
new file mode 100644
index 00000000000..49750d80761
--- /dev/null
+++ b/dev-libs/marisa/files/marisa-0.2.6-riscv_word_size.patch
@@ -0,0 +1,11 @@
+--- a/include/marisa/base.h
++++ b/include/marisa/base.h
+@@ -31,7 +31,7 @@
+ #if defined(_WIN64) || defined(__amd64__) || defined(__x86_64__) || \
+     defined(__ia64__) || defined(__ppc64__) || defined(__powerpc64__) || \
+     defined(__sparc64__) || defined(__mips64__) || defined(__aarch64__) || \
+-    defined(__s390x__)
++    defined(__s390x__) || (defined(__riscv) && (__riscv_xlen == 64))
+  #define MARISA_WORD_SIZE 64
+ #else  // defined(_WIN64), etc.
+  #define MARISA_WORD_SIZE 32

diff --git a/dev-libs/marisa/marisa-0.2.6.ebuild 
b/dev-libs/marisa/marisa-0.2.6.ebuild
index 1ed697e7aea..c958dfd64c3 100644
--- a/dev-libs/marisa/marisa-0.2.6.ebuild
+++ b/dev-libs/marisa/marisa-0.2.6.ebuild
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI="7"
-PYTHON_COMPAT=(python{3_7,3_8,3_9})
+PYTHON_COMPAT=( python3_{8,9} )
 DISTUTILS_OPTIONAL="1"
 DISTUTILS_USE_SETUPTOOLS="no"
 
@@ -24,7 +24,7 @@ fi
 
 LICENSE="|| ( BSD-2 LGPL-2.1+ )"
 SLOT="0"
-KEYWORDS="~amd64 ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+KEYWORDS="~amd64 ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc ~x86"
 IUSE="python static-libs"
 REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
 
@@ -39,6 +39,10 @@ if [[ "${PV}" != "9999" ]]; then
        S="${WORKDIR}/marisa-trie-${PV}"
 fi
 
+PATCHES=(
+       "${FILESDIR}"/${PN}-0.2.6-riscv_word_size.patch
+)
+
 src_prepare() {
        default
        eautoreconf

Reply via email to