<pre style='margin:0'>
Clemens Lang (neverpanic) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/8b7f401ee9079d65b713bff165f89af982cca216">https://github.com/macports/macports-ports/commit/8b7f401ee9079d65b713bff165f89af982cca216</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 8b7f401 guile: Fix build on Sierra
</span>8b7f401 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 8b7f401ee9079d65b713bff165f89af982cca216
</span>Author: Clemens Lang <cal@macports.org>
AuthorDate: Mon Jan 9 01:04:45 2017 +0100
<span style='display:block; white-space:pre;color:#404040;'> guile: Fix build on Sierra
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> macOS Sierra introduces a mkostemp(3) function which is used when
</span><span style='display:block; white-space:pre;color:#404040;'> present. Contrary to the GNUlib version of mkostemp(3) that was used
</span><span style='display:block; white-space:pre;color:#404040;'> previously, this version fails with 'invalid argument' when flags other
</span><span style='display:block; white-space:pre;color:#404040;'> than from a specified set are passed. From mktemp(3):
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> | The mkostemp() function is like mkstemp() but allows specifying
</span><span style='display:block; white-space:pre;color:#404040;'> | additional open(2) flags (defined in <fcntl.h>). The permitted flags
</span><span style='display:block; white-space:pre;color:#404040;'> | are O_APPEND, O_SHLOCK, O_EXLOCK and O_CLOEXEC.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Apply a patch that avoids unsupported flags to fix this problem.
</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/52613
</span>---
lang/guile/Portfile | 3 ++-
...sierra-filter-incompatible-mkostemp-flags.patch | 28 ++++++++++++++++++++++
2 files changed, 30 insertions(+), 1 deletion(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/guile/Portfile b/lang/guile/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index aee5572..717902b 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/lang/guile/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/guile/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -58,7 +58,8 @@ configure.args CPPFLAGS="-I${prefix}/include" \
</span> --disable-error-on-warning \
--disable-silent-rules
<span style='display:block; white-space:pre;background:#ffe0e0;'>-patchfiles sierra.patch
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles sierra.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sierra-filter-incompatible-mkostemp-flags.patch
</span>
# Unable to cross compile, so we need to be able to run the built code
if {${os.arch} eq "i386" && ${os.major} >= 11} {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/guile/files/sierra-filter-incompatible-mkostemp-flags.patch b/lang/guile/files/sierra-filter-incompatible-mkostemp-flags.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..cde2def
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/guile/files/sierra-filter-incompatible-mkostemp-flags.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,28 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Filter incompat. mkostemp(3) flags on macOS 10.12
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+macOS Sierra introduces a mkostemp(3) function which is used when
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+present. Contrary to the GNUlib version of mkostemp(3) that was used
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+previously, this version fails with 'invalid argument' when flags other
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+than from a specified set are passed. From mktemp(3):
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+| The mkostemp() function is like mkstemp() but allows specifying
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+| additional open(2) flags (defined in <fcntl.h>). The permitted flags
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+| are O_APPEND, O_SHLOCK, O_EXLOCK and O_CLOEXEC.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Signed-off-by: Clemens Lang <cal@macports.org>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Upstream-Status: Submitted [https://debbugs.gnu.org/cgi/bugreport.cgi?bug=24862#23]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- libguile/filesys.c.orig 2017-01-09 00:53:27.000000000 +0100
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ libguile/filesys.c 2017-01-09 00:54:48.000000000 +0100
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1486,6 +1486,12 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ mode_bits = scm_i_mode_bits (mode);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifdef __APPLE__
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* macOS starting with 10.12 defines mkostemp(2) which is used if defined,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * but only accepts some flags according to its manpage. It fails with
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * invalid argument when other flags are passed. */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ open_flags &= O_APPEND | O_SHLOCK | O_EXLOCK | O_CLOEXEC;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ SCM_SYSCALL (rv = mkostemp (c_tmpl, open_flags));
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (rv == -1)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ SCM_SYSERROR;
</span></pre><pre style='margin:0'>
</pre>