commit: 8b4c946f772a68959ba2294607f0e8280ab7f18a Author: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> AuthorDate: Thu Dec 30 14:21:06 2021 +0000 Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org> CommitDate: Thu Dec 30 14:43:21 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8b4c946f
media-libs/libvpx: build ppc64le-linux-gcc target on power9 cpu it may build on power7 and power8 with vsx codepaths, but will fail testsuite and at runtime. So only enable vsx codepaths on power9 CPUs, it's the only one that makes sense anyway. testsuite passes with flying colors, same as generic-gnu target. [==========] 952 tests from 48 test suites ran. NOTE: previous versions also built ppc64le-linux-gcc target via auto-detection. so not much changes, we just make it explicit. Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org> media-libs/libvpx/libvpx-1.11.0.ebuild | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/media-libs/libvpx/libvpx-1.11.0.ebuild b/media-libs/libvpx/libvpx-1.11.0.ebuild index 7d495a5048b8..186980591136 100644 --- a/media-libs/libvpx/libvpx-1.11.0.ebuild +++ b/media-libs/libvpx/libvpx-1.11.0.ebuild @@ -22,7 +22,7 @@ SRC_URI="https://github.com/webmproject/${PN}/archive/v${PV}.tar.gz -> ${P}.tar. LICENSE="BSD" SLOT="0/7" KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" -IUSE="doc +highbitdepth postproc static-libs test +threads" +IUSE="cpu_flags_ppc_vsx3 doc +highbitdepth postproc static-libs test +threads" REQUIRED_USE="test? ( threads )" @@ -94,6 +94,9 @@ multilib_src_configure() { myconfargs+=( --force-target=arm64-linux-gcc ) elif [[ ${ABI} == arm ]] && [[ ${CHOST} == *armv7* ]] ; then myconfargs+=( --force-target=armv7-linux-gcc ) + elif [[ ${ABI} == ppc64 ]] && [[ $(tc-endian) != big ]] && use cpu_flags_ppc_vsx3; then + # only enable this target for at least power9 CPU running little-endian + myconfargs+=( --force-target=ppc64le-linux-gcc ) else myconfargs+=( --force-target=generic-gnu ) fi
