<pre style='margin:0'>
Joshua Root (jmroot) pushed a commit to branch master
in repository macports-ports.

</pre>
<p><a href="https://github.com/macports/macports-ports/commit/5019985e74e087acdcdf8649a8c3b4ce1779001b">https://github.com/macports/macports-ports/commit/5019985e74e087acdcdf8649a8c3b4ce1779001b</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 5019985e74e087acdcdf8649a8c3b4ce1779001b
</span>Author: Joshua Root <jmr@macports.org>
AuthorDate: Wed Jan 10 14:52:34 2024 +1100

<span style='display:block; white-space:pre;color:#404040;'>    py38-matplotlib: disable -Werror
</span>---
 .../py-matplotlib/files/patch-v37-setupext.py.diff | 56 ++++++++++------------
 1 file changed, 24 insertions(+), 32 deletions(-)

<span style='display:block; white-space:pre;color:#808080;'>diff --git a/python/py-matplotlib/files/patch-v37-setupext.py.diff b/python/py-matplotlib/files/patch-v37-setupext.py.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index ca10116075c..31ef25bc9c0 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/python/py-matplotlib/files/patch-v37-setupext.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/python/py-matplotlib/files/patch-v37-setupext.py.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---- setupext.py.orig       2022-08-10 22:00:22.000000000 -0400
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+++ setupext.py    2022-08-17 21:46:17.000000000 -0400
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -391,6 +391,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- setupext.py.orig       2023-02-22 11:42:35
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ setupext.py    2024-01-10 14:48:42
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -399,6 +399,7 @@
</span>                  "src/_backend_agg_wrapper.cpp",
              ])
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,23 +8,15 @@
</span>          add_libagg_flags_and_sources(ext)
          FreeType.add_flags(ext)
          yield ext
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -401,6 +402,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -409,6 +410,7 @@
</span>                  "linux": ["dl"],
                  "win32": ["ole32", "shell32", "user32"],
              }.get(sys.platform, [])))
 +        add_macports_flags(ext)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-         yield ext
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         # contour
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         ext = Extension(
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -410,6 +412,7 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-                 "src/py_converters.cpp",
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-             ])
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         add_numpy_flags(ext)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+        add_macports_flags(ext)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         add_libagg_flags(ext)
</span>          yield ext
          # ft2font
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -421,6 +424,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         ext = Extension(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -419,6 +421,7 @@
</span>              ])
          FreeType.add_flags(ext)
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -32,7 +24,7 @@
</span>          add_libagg_flags(ext)
          yield ext
          # image
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -430,6 +434,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -428,6 +431,7 @@
</span>                  "src/py_converters.cpp",
              ])
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -40,7 +32,7 @@
</span>          add_libagg_flags_and_sources(ext)
          yield ext
          # path
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -439,6 +444,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -437,6 +441,7 @@
</span>                  "src/_path_wrapper.cpp",
              ])
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -48,15 +40,15 @@
</span>          add_libagg_flags_and_sources(ext)
          yield ext
          # qhull
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -446,6 +452,7 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-             "matplotlib._qhull", ["src/qhull_wrap.cpp"],
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -444,6 +449,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             "matplotlib._qhull", ["src/_qhull_wrapper.cpp"],
</span>              define_macros=[("MPL_DEVNULL", os.devnull)])
          add_numpy_flags(ext)
 +        add_macports_flags(ext)
          Qhull.add_flags(ext)
          yield ext
          # tkagg
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -459,6 +466,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -457,6 +463,7 @@
</span>                         "cygwin": ["comctl32", "psapi"]}.get(sys.platform, []),
              extra_link_args={"win32": ["-mwindows"]}.get(sys.platform, []))
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -64,15 +56,15 @@
</span>          add_libagg_flags(ext)
          yield ext
          # tri
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -468,6 +476,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -466,6 +473,7 @@
</span>                  "src/tri/_tri_wrapper.cpp",
<span style='display:block; white-space:pre;background:#ffe0e0;'>-             ])
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         add_numpy_flags(ext)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             ],
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             cxx_std=11)
</span> +        add_macports_flags(ext)
          yield ext
          # ttconv
          ext = Extension(
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -479,9 +488,11 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -477,6 +485,7 @@
</span>              ],
              include_dirs=["extern"])
          add_numpy_flags(ext)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -80,23 +72,23 @@
</span>          yield ext
  
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- class Tests(OptionalPackage):
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-     name = "tests"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-     default_config = False
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -501,6 +512,11 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -504,6 +513,11 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             ]
</span>          }
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>- 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span> +def add_macports_flags(ext):
 +    mp_cxxflags = os.getenv('CXXFLAGS').split()
 +    print(f"MacPorts CXXFLAGS = {mp_cxxflags}")
 +    ext.extra_compile_args.extend(mp_cxxflags)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span>  def add_numpy_flags(ext):
      import numpy as np
<span style='display:block; white-space:pre;background:#ffe0e0;'>-     ext.include_dirs.append(np.get_include())
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -771,4 +787,5 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -796,8 +810,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             'matplotlib.backends._macosx', [
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                 'src/_macosx.m'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             ])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-        ext.extra_compile_args.extend(['-Werror'])
</span>          ext.extra_link_args.extend(['-framework', 'Cocoa'])
          if platform.python_implementation().lower() == 'pypy':
              ext.extra_compile_args.append('-DPYPY=1')
</pre><pre style='margin:0'>

</pre>