commit:     89876c7b01a7404bd047ec122821665794d8dff6
Author:     Alfred Wingate <parona <AT> protonmail <DOT> com>
AuthorDate: Thu Jan 15 15:43:48 2026 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jan 15 19:28:48 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=89876c7b

media-libs/gegl: respect NM

Closes: https://bugs.gentoo.org/968162
Signed-off-by: Alfred Wingate <parona <AT> protonmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/45388
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-libs/gegl/files/gegl-0.4.66-respect-NM.patch | 25 ++++++++++++++++++++++
 media-libs/gegl/gegl-0.4.66.ebuild                 |  4 ++++
 2 files changed, 29 insertions(+)

diff --git a/media-libs/gegl/files/gegl-0.4.66-respect-NM.patch 
b/media-libs/gegl/files/gegl-0.4.66-respect-NM.patch
new file mode 100644
index 000000000000..1baf9d3be257
--- /dev/null
+++ b/media-libs/gegl/files/gegl-0.4.66-respect-NM.patch
@@ -0,0 +1,25 @@
+https://bugs.gentoo.org/968162
+
+diff --git a/tools/defcheck.py b/tools/defcheck.py
+index 3103481..30d875f 100644
+--- a/tools/defcheck.py
++++ b/tools/defcheck.py
+@@ -31,7 +31,7 @@ Needs the tool "nm" to work
+ 
+ import sys, subprocess
+ 
+-from os import path
++from os import getenv, path
+ 
+ def_files = sys.argv[1:]
+ 
+@@ -65,7 +65,7 @@ for df in def_files:
+    #      unsortindex = i+1
+    #      break;
+ 
+-   status, nm = subprocess.getstatusoutput ("nm --defined-only --extern-only 
" +
++   status, nm = subprocess.getstatusoutput (getenv("NM", default="nm") + " 
--defined-only --extern-only " +
+                                             libname)
+    if status != 0:
+       print("trouble reading {} - has it been compiled?".format(libname))
+

diff --git a/media-libs/gegl/gegl-0.4.66.ebuild 
b/media-libs/gegl/gegl-0.4.66.ebuild
index 062091e88d5e..a8ae5129d1e3 100644
--- a/media-libs/gegl/gegl-0.4.66.ebuild
+++ b/media-libs/gegl/gegl-0.4.66.ebuild
@@ -73,6 +73,10 @@ BDEPEND="
 
 DOCS=( AUTHORS docs/ChangeLog docs/NEWS.adoc )
 
+PATCHES=(
+       "${FILESDIR}"/gegl-0.4.66-respect-NM.patch
+)
+
 pkg_pretend() {
        [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp
 }

Reply via email to