[MacPorts] #55765: textmate2 @2.0-rc.4_1: build fails under sierra (10.12.6) with error: command execution failed

MacPorts noreply at macports.org
Wed Jan 31 21:35:37 UTC 2018


#55765: textmate2 @2.0-rc.4_1: build fails under sierra (10.12.6) with error:
command execution failed
------------------------+------------------------
  Reporter:  vinteles   |      Owner:  neverpanic
      Type:  defect     |     Status:  assigned
  Priority:  Normal     |  Milestone:
 Component:  ports      |    Version:  2.4.2
Resolution:             |   Keywords:
      Port:  textmate2  |
------------------------+------------------------

Comment (by neverpanic):

 I can get the build working with these patches:

 {{{
 #!patch
 diff --git a/editors/textmate2/Portfile b/editors/textmate2/Portfile
 index 7559f5bd00..c51070c010 100644
 --- a/editors/textmate2/Portfile
 +++ b/editors/textmate2/Portfile
 @@ -32,7 +32,9 @@ post-fetch {
  }

  patchfiles              patch-configure-versionnumber.diff \
 -                        patch-Applications_commit_target.diff
 +                        patch-Applications_commit_target.diff \
 +                        49cc123544edb219a9fd131c68837e32bfaa271d.patch \
 +                        patch-
 Applications_TextMate_about_Contributions.md.diff

  post-patch {
      reinplace "s/@VERSION@/${version}/" ${worksrcpath}/configure
 diff --git
 a/editors/textmate2/files/49cc123544edb219a9fd131c68837e32bfaa271d.patch
 b/editors/textmate2/files/49cc123544edb219a9fd131c68837e32bfaa271d.patch
 new file mode 100644
 index 0000000000..1b83239ccf
 --- /dev/null
 +++
 b/editors/textmate2/files/49cc123544edb219a9fd131c68837e32bfaa271d.patch
 @@ -0,0 +1,26 @@
 +From 49cc123544edb219a9fd131c68837e32bfaa271d Mon Sep 17 00:00:00 2001
 +From: Ronald Wampler <rdwampler at gmail.com>
 +Date: Fri, 23 Jun 2017 10:44:28 -0400
 +Subject: [PATCH] Change `std::vector< std::pair<char const*, char const*>
 >`
 + to `auto` (C++17)
 +
 +C++17 added a non-const overload for std::string::data().
 +
 +Upstream-Status: Backport
 [https://github.com/textmate/textmate/commit/49cc123544edb219a9fd131c68837e32bfaa271d]
 +---
 + Frameworks/editor/src/editor.cc | 2 +-
 + 1 file changed, 1 insertion(+), 1 deletion(-)
 +
 +diff --git ./Frameworks/editor/src/editor.cc
 ./Frameworks/editor/src/editor.cc
 +index 308633444..58488bf0c 100644
 +--- ./Frameworks/editor/src/editor.cc
 ++++ ./Frameworks/editor/src/editor.cc
 +@@ -546,7 +546,7 @@ namespace ng
 +
 +                               int minIndent = INT_MAX;
 +
 +-                              std::vector< std::pair<char const*, char
 const*> > const& v = text::to_lines(str.data(), str.data() + str.size());
 ++                              auto const& v = text::to_lines(str.data(),
 str.data() + str.size());
 +                               for(auto const& it : v)
 +                               {
 +                                       if(!text::is_blank(it.first,
 it.second))
 diff --git a/editors/textmate2/files/patch-
 Applications_TextMate_about_Contributions.md.diff
 b/editors/textmate2/files/patch-
 Applications_TextMate_about_Contributions.md.diff
 new file mode 100644
 index 0000000000..32b72ab119
 --- /dev/null
 +++ b/editors/textmate2/files/patch-
 Applications_TextMate_about_Contributions.md.diff
 @@ -0,0 +1,39 @@
 +Fix generation of contribution page
 +
 +Modern multimarkdown tends to convert the <% and %> tags into HTML when
 they
 +occur before or after an empty line. This would then break parsing with
 erb.
 +Remove all empty lines in the vincinity of these tags to prevent this
 problem.
 +
 +Additionally, move the cache file for the githubcredits into the build
 +directory, because the home is either not writable, or not preserved
 within
 +MacPorts builds, and attempting to re-generate these texts too often
 usually
 +causes one to hit the GitHub API limit. By putting the file into the
 build
 +directory, aborted builds can at least be re-started without hitting any
 API
 +limits.
 +
 +Upstream-Status: Inappropriate [configuration]
 +--- Applications/TextMate/about/Contributions.md.orig  2018-01-31
 21:46:35.000000000 +0100
 ++++ Applications/TextMate/about/Contributions.md       2018-01-31
 22:21:35.000000000 +0100
 +@@ -8,13 +8,11 @@
 +
 + <div>
 + <%# this wrapping div prevents Markdown from trying to parse the ERB
 blocks %>
 +-
 + <%
 + last_group_heading = ''
 + require File.join(File.dirname(__FILE__), 'bin/gen_credits')
 +-generate_credits(File.expand_path('~/Library/Caches/com.macromates.TextMate/githubcredits'),
 warn) do |hash, author, subject, body, userpic, date, github_user|
 ++generate_credits(File.expand_path('githubcredits'), warn) do |hash,
 author, subject, body, userpic, date, github_user|
 +   group_heading = date.strftime('%b %e, %Y')
 +-
 +   if last_group_heading != group_heading
 +     if last_group_heading != ''
 +         _erbout << "</ol>\n"
 +@@ -49,7 +47,6 @@
 +   </li>
 + <%
 + end
 +-
 + if last_group_heading != ''
 +     _erbout << "</ol>\n"
 + end
 }}}

 However, the binary built on 10.13 crashes immediately on startup with
 various memory corruption errors. Can you confirm this happens for you as
 well?

 I really don't have the time at the moment to look into these memory
 issues. Help welcome.

--
Ticket URL: <https://trac.macports.org/ticket/55765#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list