commit:     43dafe5bc3206ad6336d7d68c18eb79ecf5a0710
Author:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Mon Jun 17 15:40:52 2019 +0000
Commit:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Mon Jun 17 15:42:04 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=43dafe5b

x11-libs/pixman: Use tc-has-openmp

Closes: https://bugs.gentoo.org/684656
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>

 x11-libs/pixman/pixman-0.38.4.ebuild | 7 +++++--
 x11-libs/pixman/pixman-9999.ebuild   | 7 +++++--
 2 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/x11-libs/pixman/pixman-0.38.4.ebuild 
b/x11-libs/pixman/pixman-0.38.4.ebuild
index 3fbd5e9c832..b5fcceac957 100644
--- a/x11-libs/pixman/pixman-0.38.4.ebuild
+++ b/x11-libs/pixman/pixman-0.38.4.ebuild
@@ -9,7 +9,7 @@ if [[ ${PV} = 9999* ]]; then
        GIT_ECLASS="git-r3"
 fi
 
-inherit ${GIT_ECLASS} meson multilib-minimal
+inherit ${GIT_ECLASS} meson multilib-minimal toolchain-funcs
 
 DESCRIPTION="Low-level pixel manipulation routines"
 HOMEPAGE="http://www.pixman.org/ https://gitlab.freedesktop.org/pixman/pixman/";
@@ -30,6 +30,9 @@ src_unpack() {
 }
 
 multilib_src_configure() {
+       local openmp=disabled
+       tc-has-openmp && openmp=enabled
+
        local emesonargs=(
                $(meson_feature cpu_flags_arm_iwmmxt iwmmxt)
                $(meson_use     cpu_flags_arm_iwmmxt2 iwmmxt2)
@@ -41,7 +44,7 @@ multilib_src_configure() {
                $(meson_feature loongson2f loongson-mmi)
                -Dgtk=disabled
                -Dlibpng=disabled
-               -Dopenmp=auto # only used in unit tests
+               -Dopenmp=$openmp # only used in unit tests
        )
        meson_src_configure
 }

diff --git a/x11-libs/pixman/pixman-9999.ebuild 
b/x11-libs/pixman/pixman-9999.ebuild
index 58862e4166b..0e6923456a8 100644
--- a/x11-libs/pixman/pixman-9999.ebuild
+++ b/x11-libs/pixman/pixman-9999.ebuild
@@ -9,7 +9,7 @@ if [[ ${PV} = 9999* ]]; then
        GIT_ECLASS="git-r3"
 fi
 
-inherit ${GIT_ECLASS} meson multilib-minimal
+inherit ${GIT_ECLASS} meson multilib-minimal toolchain-funcs
 
 DESCRIPTION="Low-level pixel manipulation routines"
 HOMEPAGE="http://www.pixman.org/ https://gitlab.freedesktop.org/pixman/pixman/";
@@ -30,6 +30,9 @@ src_unpack() {
 }
 
 multilib_src_configure() {
+       local openmp=disabled
+       tc-has-openmp && openmp=enabled
+
        local emesonargs=(
                $(meson_feature cpu_flags_arm_iwmmxt iwmmxt)
                $(meson_use     cpu_flags_arm_iwmmxt2 iwmmxt2)
@@ -41,7 +44,7 @@ multilib_src_configure() {
                $(meson_feature loongson2f loongson-mmi)
                -Dgtk=disabled
                -Dlibpng=disabled
-               -Dopenmp=auto # only used in unit tests
+               -Dopenmp=$openmp # only used in unit tests
        )
        meson_src_configure
 }

Reply via email to