commit:     ee0ebdf8b66069d30913d066a13ed712a305bada
Author:     David Seifert <soap <AT> gentoo <DOT> org>
AuthorDate: Sat May 14 21:30:10 2022 +0000
Commit:     David Seifert <soap <AT> gentoo <DOT> org>
CommitDate: Sat May 14 21:30:10 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ee0ebdf8

media-gfx/graphicsmagick: [QA] tc-has-openmp → tc-check-openmp

Signed-off-by: David Seifert <soap <AT> gentoo.org>

 media-gfx/graphicsmagick/graphicsmagick-1.3.37.ebuild | 15 +++++++++------
 media-gfx/graphicsmagick/graphicsmagick-1.3.38.ebuild |  7 +------
 media-gfx/graphicsmagick/graphicsmagick-9999.ebuild   |  7 +------
 3 files changed, 11 insertions(+), 18 deletions(-)

diff --git a/media-gfx/graphicsmagick/graphicsmagick-1.3.37.ebuild 
b/media-gfx/graphicsmagick/graphicsmagick-1.3.37.ebuild
index 03a95689ff0e..85263d8a19fe 100644
--- a/media-gfx/graphicsmagick/graphicsmagick-1.3.37.ebuild
+++ b/media-gfx/graphicsmagick/graphicsmagick-1.3.37.ebuild
@@ -57,6 +57,14 @@ PATCHES=(
        "${FILESDIR}"/${PN}-1.3.19-perl.patch
 )
 
+pkg_pretend() {
+       [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
+pkg_setup() {
+       [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
+}
+
 src_prepare() {
        default
 
@@ -68,19 +76,14 @@ src_configure() {
        use q16 && depth=16
        use q32 && depth=32
 
-       local openmp=disable
-       if use openmp && tc-has-openmp ; then
-               openmp=enable
-       fi
-
        local myeconfargs=(
-               --${openmp}-openmp
                --enable-largefile
                --enable-shared
                $(use_enable static-libs static)
                $(use_enable debug prof)
                $(use_enable debug gcov)
                $(use_enable imagemagick magick-compat)
+               $(use_enable openmp)
                $(use_with threads)
                $(use_with dynamic-loading modules)
                --with-quantum-depth=${depth}

diff --git a/media-gfx/graphicsmagick/graphicsmagick-1.3.38.ebuild 
b/media-gfx/graphicsmagick/graphicsmagick-1.3.38.ebuild
index c640b1b4cc74..bd91b4160147 100644
--- a/media-gfx/graphicsmagick/graphicsmagick-1.3.38.ebuild
+++ b/media-gfx/graphicsmagick/graphicsmagick-1.3.38.ebuild
@@ -91,6 +91,7 @@ src_configure() {
                $(use_enable debug prof)
                $(use_enable debug gcov)
                $(use_enable imagemagick magick-compat)
+               $(use_enable openmp)
                $(use_with threads)
                $(use_with dynamic-loading modules)
                --with-quantum-depth=${depth}
@@ -121,12 +122,6 @@ src_configure() {
                $(use_with X x)
        )
 
-       if use openmp && tc-has-openmp ; then
-               myeconfargs+=( --enable-openmp )
-       else
-               myeconfargs+=( --disable-openmp )
-       fi
-
        econf "${myeconfargs[@]}"
 }
 

diff --git a/media-gfx/graphicsmagick/graphicsmagick-9999.ebuild 
b/media-gfx/graphicsmagick/graphicsmagick-9999.ebuild
index c640b1b4cc74..bd91b4160147 100644
--- a/media-gfx/graphicsmagick/graphicsmagick-9999.ebuild
+++ b/media-gfx/graphicsmagick/graphicsmagick-9999.ebuild
@@ -91,6 +91,7 @@ src_configure() {
                $(use_enable debug prof)
                $(use_enable debug gcov)
                $(use_enable imagemagick magick-compat)
+               $(use_enable openmp)
                $(use_with threads)
                $(use_with dynamic-loading modules)
                --with-quantum-depth=${depth}
@@ -121,12 +122,6 @@ src_configure() {
                $(use_with X x)
        )
 
-       if use openmp && tc-has-openmp ; then
-               myeconfargs+=( --enable-openmp )
-       else
-               myeconfargs+=( --disable-openmp )
-       fi
-
        econf "${myeconfargs[@]}"
 }
 

Reply via email to