<pre style='margin:0'>
Ken (kencu) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/bda78c75fc1fe33d3e40edebb07e4420d7aa93ce">https://github.com/macports/macports-ports/commit/bda78c75fc1fe33d3e40edebb07e4420d7aa93ce</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 bda78c7 fish: fix build on Leopard and earlier
</span>bda78c7 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit bda78c75fc1fe33d3e40edebb07e4420d7aa93ce
</span>Author: Ken Cunningham <kencu@macports.org>
AuthorDate: Wed Oct 4 23:29:16 2017 -0700
<span style='display:block; white-space:pre;color:#404040;'> fish: fix build on Leopard and earlier
</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/54974
</span>---
shells/fish/Portfile | 6 ++++++
shells/fish/files/patch-src-wutil-leopard.diff | 15 +++++++++++++++
2 files changed, 21 insertions(+)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/shells/fish/Portfile b/shells/fish/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 4b76e06..414efaa 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/shells/fish/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/shells/fish/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -6,6 +6,7 @@ PortGroup cxx11 1.1
</span>
github.setup fish-shell fish-shell 2.6.0
name fish
<span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 1
</span> license GPL-2
categories shells
platforms darwin
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -27,6 +28,11 @@ depends_lib port:libiconv \
</span>
patchfiles patch-share_config_fish.diff
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# fix error on Leopard and earlier
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if { ${os.platform} eq "darwin" && ${os.major} < 10 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles-append patch-src-wutil-leopard.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> post-patch {
reinplace "s|@@PREFIX@@|${prefix}/bin|g" "${worksrcpath}/share/config.fish"
reinplace "s|DEF_VER=2.0.GIT|DEF_VER=${version}|" ${worksrcpath}/build_tools/git_version_gen.sh
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/shells/fish/files/patch-src-wutil-leopard.diff b/shells/fish/files/patch-src-wutil-leopard.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..2b59fc6
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/shells/fish/files/patch-src-wutil-leopard.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,15 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git a/src/wutil.cpp b/src/wutil.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index a65a7648..06b144be 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/wutil.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/wutil.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -349,8 +349,8 @@ wchar_t *wrealpath(const wcstring &pathname, wchar_t *resolved_path) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ while (narrow_path.size() > 1 && narrow_path.at(narrow_path.size() - 1) == '/') {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ narrow_path.erase(narrow_path.size() - 1, 1);
</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;'>+- char *narrow_res = realpath(narrow_path.c_str(), NULL);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char tmpbuf[PATH_MAX];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char *narrow_res = realpath(narrow_path.c_str(), tmpbuf);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (narrow_res) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ real_path.append(narrow_res);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span></pre><pre style='margin:0'>
</pre>