<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/1179dd74a14fa1980caf2ddc033a2236b03a67be">https://github.com/macports/macports-ports/commit/1179dd74a14fa1980caf2ddc033a2236b03a67be</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new 1179dd7 gcam: Fix build failure with libpng 1.5+
</span>1179dd7 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 1179dd74a14fa1980caf2ddc033a2236b03a67be
</span>Author: Ryan Schmidt <ryandesign@macports.org>
AuthorDate: Wed May 29 06:38:01 2019 -0500
<span style='display:block; white-space:pre;color:#404040;'> gcam: Fix build failure with libpng 1.5+
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Closes: https://trac.macports.org/ticket/57220
</span>---
cad/gcam/Portfile | 6 +++++-
cad/gcam/files/libpng-1.5.patch | 34 ++++++++++++++++++++++++++++++++++
2 files changed, 39 insertions(+), 1 deletion(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/cad/gcam/Portfile b/cad/gcam/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 8ff59ba..a4246a5 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/cad/gcam/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/cad/gcam/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -19,5 +19,9 @@ master_sites http://gcam.js.cx/files/
</span> checksums md5 8397112e0c22b5f4a883c4808891bc2c \
sha1 a007a1a5d528ec7f3513504242991fe399f0ba65 \
rmd160 a2f412b3b09803963f2d74a5f828b0029369a596
<span style='display:block; white-space:pre;background:#ffe0e0;'>-depends_lib port:gtkglext
</span> depends_build port:pkgconfig
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+depends_lib port:gtkglext \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:libpng
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles libpng-1.5.patch
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/cad/gcam/files/libpng-1.5.patch b/cad/gcam/files/libpng-1.5.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..3f53b80
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/cad/gcam/files/libpng-1.5.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,34 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Compatibility with libpng 1.5 and later.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- libgcode/gcode_image.c.orig 2010-07-23 10:15:13.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ libgcode/gcode_image.c 2019-05-29 06:27:52.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -260,8 +260,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ png_read_info (png_ptr, info_ptr);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- image->res[0] = info_ptr->width;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- image->res[1] = info_ptr->height;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ image->res[0] = png_get_image_width (png_ptr, info_ptr);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ image->res[1] = png_get_image_height (png_ptr, info_ptr);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ /* printf ("image size: %dx%d\n", image->res[0], image->res[1]); */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -274,16 +274,16 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ row_pointers = (png_bytep *) malloc (sizeof (png_bytep) * image->res[1]);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ for (y = 0; y < image->res[1]; y++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- row_pointers[y] = (png_byte*) malloc (info_ptr->rowbytes);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ row_pointers[y] = (png_byte*) malloc (png_get_rowbytes (png_ptr, info_ptr));
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ png_read_image (png_ptr, row_pointers);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ image->dmap = (gfloat_t *) malloc (sizeof (gfloat_t) * image->res[0] * image->res[1]);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ incr = 1;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- if (info_ptr->color_type & PNG_COLOR_MASK_COLOR)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (png_get_color_type (png_ptr, info_ptr) & PNG_COLOR_MASK_COLOR)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ incr = 3;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- if (info_ptr->color_type & PNG_COLOR_MASK_ALPHA)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (png_get_color_type (png_ptr, info_ptr) & PNG_COLOR_MASK_ALPHA)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ incr = 4;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ for (y = 0; y < image->res[1]; y++)
</span></pre><pre style='margin:0'>
</pre>