From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-cpp/abseil-cpp/, dev-cpp/abseil-cpp/files/
Date: Thu, 29 Apr 2021 04:05:02 +0000 (UTC) [thread overview]
Message-ID: <1619669074.6459947b9a21796aa2980fce0e16f25a9bb37294.sam@gentoo> (raw)
commit: 6459947b9a21796aa2980fce0e16f25a9bb37294
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 29 03:02:48 2021 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Apr 29 04:04:34 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6459947b
dev-cpp/abseil-cpp: backport fix for arm64 CPUs without crypto extensions
* Backport fix for arm64 CPUs without crypto extensions
(needed for a keywording bug).
* Add information in patch / background on the problem
(including mentioning the need for an ebuild change,
in case e.g. another distro tries to pick it up,
and to remind us to try upstream it.)
* Add explicit flag-o-matic inherits accordingly.
See: 619cfe3daec298493d31030008efc12e5ebbf7ec
Bug: https://bugs.gentoo.org/778926
Bug: https://bugs.gentoo.org/766411
Signed-off-by: Sam James <sam <AT> gentoo.org>
dev-cpp/abseil-cpp/abseil-cpp-20200225.2-r1.ebuild | 13 ++++++++++++-
dev-cpp/abseil-cpp/abseil-cpp-20200923.2-r1.ebuild | 3 ++-
dev-cpp/abseil-cpp/abseil-cpp-20210324.1.ebuild | 3 ++-
.../files/abseil-cpp-20200923-arm_no_crypto.patch | 7 +++++++
4 files changed, 23 insertions(+), 3 deletions(-)
diff --git a/dev-cpp/abseil-cpp/abseil-cpp-20200225.2-r1.ebuild b/dev-cpp/abseil-cpp/abseil-cpp-20200225.2-r1.ebuild
index 344942f1eca..a4ec361d4c0 100644
--- a/dev-cpp/abseil-cpp/abseil-cpp-20200225.2-r1.ebuild
+++ b/dev-cpp/abseil-cpp/abseil-cpp-20200225.2-r1.ebuild
@@ -5,7 +5,7 @@ EAPI=7
PYTHON_COMPAT=( python3_{7,8,9} )
-inherit cmake python-any-r1
+inherit cmake flag-o-matic python-any-r1
DESCRIPTION="Abseil Common Libraries (C++), LTS Branch"
HOMEPAGE="https://abseil.io"
@@ -23,6 +23,10 @@ BDEPEND="${PYTHON_DEPS}"
# requires source of gtest and other libs
RESTRICT=test
+PATCHES=(
+ "${FILESDIR}/${PN}-20200923-arm_no_crypto.patch"
+)
+
src_prepare() {
cmake_src_prepare
@@ -40,6 +44,13 @@ src_prepare() {
}
src_configure() {
+ if use arm || use arm64; then
+ # bug #778926
+ if [[ $($(tc-getCXX) ${CXXFLAGS} -E -P - <<<$'#if defined(__ARM_FEATURE_CRYPTO)\nHAVE_ARM_FEATURE_CRYPTO\n#endif') != *HAVE_ARM_FEATURE_CRYPTO* ]]; then
+ append-cxxflags -DABSL_ARCH_ARM_NO_CRYPTO
+ fi
+ fi
+
local mycmakeargs=(
-DABSL_ENABLE_INSTALL=TRUE
)
diff --git a/dev-cpp/abseil-cpp/abseil-cpp-20200923.2-r1.ebuild b/dev-cpp/abseil-cpp/abseil-cpp-20200923.2-r1.ebuild
index a5ffd719aa2..d15b9e966d8 100644
--- a/dev-cpp/abseil-cpp/abseil-cpp-20200923.2-r1.ebuild
+++ b/dev-cpp/abseil-cpp/abseil-cpp-20200923.2-r1.ebuild
@@ -5,7 +5,7 @@ EAPI=7
PYTHON_COMPAT=( python3_{7,8,9} )
-inherit cmake python-any-r1 toolchain-funcs
+inherit cmake flag-o-matic python-any-r1 toolchain-funcs
# yes, it needs SOURCE, not just installed one
GTEST_COMMIT="aee0f9d9b5b87796ee8a0ab26b7587ec30e8858e"
@@ -59,6 +59,7 @@ src_prepare() {
src_configure() {
if use arm || use arm64; then
+ # bug #778926
if [[ $($(tc-getCXX) ${CXXFLAGS} -E -P - <<<$'#if defined(__ARM_FEATURE_CRYPTO)\nHAVE_ARM_FEATURE_CRYPTO\n#endif') != *HAVE_ARM_FEATURE_CRYPTO* ]]; then
append-cxxflags -DABSL_ARCH_ARM_NO_CRYPTO
fi
diff --git a/dev-cpp/abseil-cpp/abseil-cpp-20210324.1.ebuild b/dev-cpp/abseil-cpp/abseil-cpp-20210324.1.ebuild
index 136d41f23b4..12ecd89301f 100644
--- a/dev-cpp/abseil-cpp/abseil-cpp-20210324.1.ebuild
+++ b/dev-cpp/abseil-cpp/abseil-cpp-20210324.1.ebuild
@@ -5,7 +5,7 @@ EAPI=7
PYTHON_COMPAT=( python3_{7,8,9} )
-inherit cmake python-any-r1 toolchain-funcs
+inherit cmake flag-o-matic python-any-r1 toolchain-funcs
# yes, it needs SOURCE, not just installed one
GTEST_COMMIT="aee0f9d9b5b87796ee8a0ab26b7587ec30e8858e"
@@ -61,6 +61,7 @@ src_prepare() {
src_configure() {
if use arm || use arm64; then
+ # bug #778926
if [[ $($(tc-getCXX) ${CXXFLAGS} -E -P - <<<$'#if defined(__ARM_FEATURE_CRYPTO)\nHAVE_ARM_FEATURE_CRYPTO\n#endif') != *HAVE_ARM_FEATURE_CRYPTO* ]]; then
append-cxxflags -DABSL_ARCH_ARM_NO_CRYPTO
fi
diff --git a/dev-cpp/abseil-cpp/files/abseil-cpp-20200923-arm_no_crypto.patch b/dev-cpp/abseil-cpp/files/abseil-cpp-20200923-arm_no_crypto.patch
index b74a6c70e90..762476a1018 100644
--- a/dev-cpp/abseil-cpp/files/abseil-cpp-20200923-arm_no_crypto.patch
+++ b/dev-cpp/abseil-cpp/files/abseil-cpp-20200923-arm_no_crypto.patch
@@ -1,3 +1,10 @@
+Don't assume all ARM CPUs have crypto extensions.
+
+Requires an accompanying change in the ebuild to disable crypto
+extensions (by passing -DABSL_ARCH_ARM_NO_CRYPTO). This could
+be done by the build system instead in future.
+
+https://bugs.gentoo.org/778926
--- /absl/random/internal/randen_hwaes.cc
+++ /absl/random/internal/randen_hwaes.cc
@@ -50,8 +50,11 @@
next reply other threads:[~2021-04-29 4:05 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-29 4:05 Sam James [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-09-04 2:32 [gentoo-commits] repo/gentoo:master commit in: dev-cpp/abseil-cpp/, dev-cpp/abseil-cpp/files/ Yixun Lan
2024-07-07 0:26 Sam James
2023-11-20 10:06 Sam James
2022-08-23 7:30 WANG Xuerui
2022-06-26 2:45 Jason Zaman
2021-12-26 7:21 Georgy Yakovlev
2021-11-16 11:58 Sam James
2021-06-17 17:51 Georgy Yakovlev
2021-04-22 4:07 Georgy Yakovlev
2021-04-04 21:59 Georgy Yakovlev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1619669074.6459947b9a21796aa2980fce0e16f25a9bb37294.sam@gentoo \
--to=sam@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox