Discussion:
[MacPorts] #56944: (Clang-3.7)(10.6.8 - xcode 4.2 for snow leopard)
MacPorts
2018-08-08 07:03:23 UTC
Permalink
#56944: (Clang-3.7)(10.6.8 - xcode 4.2 for snow leopard) Error: Failed to build
ld64-127: command execution failed
----------------------------------------+-----------------------
Reporter: mrkapqa | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Keywords: libcc++ clang-3.7 llvm-3.4 | Port: clang-3.7
----------------------------------------+-----------------------
Hello ,

i tried to follow your guide here

https://trac.macports.org/wiki/LibcxxOnOlderSystems


on point 4

sudo port -v install clang-3.7

i get error message


make: Leaving directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2'
Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2"
&& /usr/bin/make -j9 -w all CC="/opt/local/bin/clang-mp-3.4"
CXX="/opt/local/bin/clang++-mp-3.4" OTHER_CPPFLAGS="-I/opt/local/include
-I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/dyld-421.2/include"
OTHER_CFLAGS="-Os -arch x86_64" OTHER_CXXFLAGS="-Os -stdlib=libc++
-stdlib=libc++ -arch x86_64" OTHER_LDFLAGS="-L/opt/local/lib
-Wl,-headerpad_max_install_names -lc++abi -stdlib=libc++ -arch x86_64"
LLVM_CONFIG=/opt/local/bin/llvm-config-mp-3.4
Exit code: 2
Error: Failed to build ld64-127: command execution failed
Error: See
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/main.log
for details.
Error: rev-upgrade failed: Error rebuilding ld64-127



Thank you
--
Ticket URL: <https://trac.macports.org/ticket/56944>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 07:03:44 UTC
Permalink
#56944: (Clang-3.7)(10.6.8 - xcode 4.2 for snow leopard) Error: Failed to build
ld64-127: command execution failed
------------------------+----------------------------------------
Reporter: mrkapqa | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords: libcc++ clang-3.7 llvm-3.4
Port: clang-3.7 |
------------------------+----------------------------------------
Changes (by mrkapqa):

* Attachment "clang.log" added.
--
Ticket URL: <https://trac.macports.org/ticket/56944>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 07:53:14 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------
Changes (by kencu):

* status: new => assigned
* keywords: libcc++ clang-3.7 llvm-3.4 =>
* port: clang-3.7 => ld64-127
* owner: (none) => jeremyhu
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 07:53:46 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------
Post by MacPorts
Hello ,
i tried to follow your guide here
https://trac.macports.org/wiki/LibcxxOnOlderSystems
on point 4
sudo port -v install clang-3.7
i get error message
make: Leaving directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2'
Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2"
&& /usr/bin/make -j9 -w all CC="/opt/local/bin/clang-mp-3.4"
CXX="/opt/local/bin/clang++-mp-3.4" OTHER_CPPFLAGS="-I/opt/local/include
-I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/dyld-421.2/include"
OTHER_CFLAGS="-Os -arch x86_64" OTHER_CXXFLAGS="-Os -stdlib=libc++
-stdlib=libc++ -arch x86_64" OTHER_LDFLAGS="-L/opt/local/lib
-Wl,-headerpad_max_install_names -lc++abi -stdlib=libc++ -arch x86_64"
LLVM_CONFIG=/opt/local/bin/llvm-config-mp-3.4
Exit code: 2
Error: Failed to build ld64-127: command execution failed
Error: See
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/main.log
for details.
Error: rev-upgrade failed: Error rebuilding ld64-127
Thank you
New description:

Hello ,

i tried to follow your guide here

https://trac.macports.org/wiki/LibcxxOnOlderSystems


on point 4
{{{
sudo port -v install clang-3.7
}}}
i get error message

{{{
make: Leaving directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2'
Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2"
&& /usr/bin/make -j9 -w all CC="/opt/local/bin/clang-mp-3.4"
CXX="/opt/local/bin/clang++-mp-3.4" OTHER_CPPFLAGS="-I/opt/local/include
-I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/dyld-421.2/include"
OTHER_CFLAGS="-Os -arch x86_64" OTHER_CXXFLAGS="-Os -stdlib=libc++
-stdlib=libc++ -arch x86_64" OTHER_LDFLAGS="-L/opt/local/lib
-Wl,-headerpad_max_install_names -lc++abi -stdlib=libc++ -arch x86_64"
LLVM_CONFIG=/opt/local/bin/llvm-config-mp-3.4
Exit code: 2
Error: Failed to build ld64-127: command execution failed
Error: See
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/main.log
for details.
Error: rev-upgrade failed: Error rebuilding ld64-127
}}}


Thank you

--
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 07:55:34 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by kencu):

So this looks like it happens during a `rev-upgrade` for some reason. Can
you tell me (or show me) what happenned just before this, to trigger that
`rev-upgrade` event?

Usually something would have been installed, then some inconsistency found
(like a `stdlib` mismatch for example) to trigger the rebuild.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:3>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 08:03:15 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by mrkapqa):

I tried to install Waterfox Browser 52 on Snow Leopard, which complained
of missing libc++.1. library, and crashes


Dyld Error Message:
Symbol not found: _strndup
Referenced from:
/Applications/Waterfox.app/Contents/MacOS/libmozglue.dylib
Expected in: /usr/lib/libSystem.B.dylib
in /Applications/Waterfox.app/Contents/MacOS/libmozglue.dylib



so i tried with Macports to overcome,


and probably during the process i tried also to install Homebrew (which
failed miserably due to curl-issue) and installed Git manually ,
maybe this could have evoked an error?
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 08:39:08 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by kencu):

Ah. Well, cleaning all this up might be a project.

In your case, you would have been OK to just
{{{
sudo port -v install libcxx
}}}
and it would have installed `/usr/lib/libc++.dylib` for you and solved the
missing library issue. However, I doubt the browser would have worked
anyway as it sounds like it's built against `10.7`.

For right now today, the best browser for 10.6 is (IMHO) Firefox 45.9.0
ESR, which you can get right here in many languages
<https://ftp.mozilla.org/pub/firefox/releases/45.9.0esr/mac/>.

That is the last Firefox available for `10.6.8`, and works pretty well,
although it is not up to date with security features.

Several of us are working to bring `TenFourFox` to older Intel systems. We
have it building and running now, and it is fully up to date with security
fixes. It is not quite ready for general use just now.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:5>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 08:49:44 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by mrkapqa):

Thank you Kencu,

if i remember correctly i tried that already before but that did not
completely solve the issue so i thought it might be worth a try to test
the long road.

i do use firefox 45 esr on my system , but it is sometimes a bit outdated
(example: twitter).
on lion 10.7 i can use waterfox 56.2 , which is otherwise also limited to
firefox 45 esr.

it seems on 10.6.8 i am stuck then for now with firefox and waterfox 48
(which opens correctly). actually, safari is best on 10.6.8 in terms of
speed, but fails quite often to open pages due to security isseus i think.

I use Tenfourfox 17 (with plugins) and Tenfourfox latest quite regularly .
i would be great if it be possible to make it also available in a docker-
like format, so that when one has 2 versions of tenfourfox installed , say
17 and a newer, the can run independently, otherwise it is a bit
complicated with the plugins and add-ons which tend to update themselves
or get deactivated.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:6>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-08 16:30:34 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------
Post by MacPorts
Hello ,
i tried to follow your guide here
https://trac.macports.org/wiki/LibcxxOnOlderSystems
on point 4
{{{
sudo port -v install clang-3.7
}}}
i get error message
{{{
make: Leaving directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2'
Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2"
&& /usr/bin/make -j9 -w all CC="/opt/local/bin/clang-mp-3.4"
CXX="/opt/local/bin/clang++-mp-3.4" OTHER_CPPFLAGS="-I/opt/local/include
-I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/dyld-421.2/include"
OTHER_CFLAGS="-Os -arch x86_64" OTHER_CXXFLAGS="-Os -stdlib=libc++
-stdlib=libc++ -arch x86_64" OTHER_LDFLAGS="-L/opt/local/lib
-Wl,-headerpad_max_install_names -lc++abi -stdlib=libc++ -arch x86_64"
LLVM_CONFIG=/opt/local/bin/llvm-config-mp-3.4
Exit code: 2
Error: Failed to build ld64-127: command execution failed
Error: See
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/main.log
for details.
Error: rev-upgrade failed: Error rebuilding ld64-127
}}}
Thank you
New description:

Hello ,

i tried to follow your guide here

wiki:LibcxxOnOlderSystems


on point 4
{{{
sudo port -v install clang-3.7
}}}
i get error message

{{{
make: Leaving directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2'
Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/ld64-127.2"
&& /usr/bin/make -j9 -w all CC="/opt/local/bin/clang-mp-3.4"
CXX="/opt/local/bin/clang++-mp-3.4" OTHER_CPPFLAGS="-I/opt/local/include
-I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/work/dyld-421.2/include"
OTHER_CFLAGS="-Os -arch x86_64" OTHER_CXXFLAGS="-Os -stdlib=libc++
-stdlib=libc++ -arch x86_64" OTHER_LDFLAGS="-L/opt/local/lib
-Wl,-headerpad_max_install_names -lc++abi -stdlib=libc++ -arch x86_64"
LLVM_CONFIG=/opt/local/bin/llvm-config-mp-3.4
Exit code: 2
Error: Failed to build ld64-127: command execution failed
Error: See
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_ld64/ld64-127/main.log
for details.
Error: rev-upgrade failed: Error rebuilding ld64-127
}}}


Thank you

--
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:8>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-10-13 06:08:36 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by snunez1):

I just went through the same process and can add a bit to this report. In
addition to WaterFox, I sense that going forward long term maintenance is
going to require a lot of self compiling, and having an update to date
toolchain will really be welcome. Somethings, like Boost, require it. I am
happy to help test. Fixing is probably beyond my abilities, but happy to
help in any way I can.

Here is what happened:

After building clang 3.7 (step 4), I get this:
{{{
---> Cleaning clang-3.7
---> Removing work directory for clang-3.7
---> Updating database of binaries
---> Scanning binaries for linking errors
---> No broken files found.
ncurses is using libstdc++ (this installation is configured to use libc++)
llvm-3.4 is using libstdc++ (this installation is configured to use
libc++)
ld64-127 is using libstdc++ (this installation is configured to use
libc++)
gettext is using libstdc++ (this installation is configured to use libc++)
db48 is using libstdc++ (this installation is configured to use libc++)
clang-3.4 is using libstdc++ (this installation is configured to use
libc++)
cctools is using libstdc++ (this installation is configured to use libc++)
---> Found 7 broken ports, determining rebuild order
You can always run 'port rev-upgrade' again to fix errors.
The following ports will be rebuilt:
db48 @4.8.30+java
ncurses @6.1
gettext @0.19.8.1
llvm-3.4 @3.4.2
ld64-127 @127.2+llvm34
clang-3.4 @3.4.2+analyzer
cctools @895+llvm34
Continue? [Y/n]:
}}}
Answered 'no' and continued with steps 5 and 6. After a long while:
{{{
ncurses is using libstdc++ (this installation is configured to use libc++)
llvm-3.4 is using libstdc++ (this installation is configured to use
libc++)
ld64-127 is using libstdc++ (this installation is configured to use
libc++)
gettext is using libstdc++ (this installation is configured to use libc++)
db48 is using libstdc++ (this installation is configured to use libc++)
clang-3.4 is using libstdc++ (this installation is configured to use
libc++)
---> Found 6 broken ports, determining rebuild order
You can always run 'port rev-upgrade' again to fix errors.
The following ports will be rebuilt:
db48 @4.8.30+java
ncurses @6.1
gettext @0.19.8.1
llvm-3.4 @3.4.2
ld64-127 @127.2+llvm34
clang-3.4 @3.4.2+analyzer
Continue? [Y/n]:
}}}
Saying 'no' here and picking up with the rest of step 6 brings us right
back to the error. Trying the rev-upgrade results in:
{{{
---> Cleaning ncurses
---> Removing work directory for ncurses
---> Computing dependencies for llvm-3.4.
---> Cleaning llvm-3.4
---> Removing work directory for llvm-3.4
Error: ld64: Variant llvm39 conflicts with llvm34
Error: Unable to open port: Error evaluating variants
Error: rev-upgrade failed: Error rebuilding ld64-127
Error: Follow https://guide.macports.org/#project.tickets to report a bug.
}}}
I also tried 'yes' at the prompts and got the same errors.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:9>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-11-07 10:17:27 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by jeremyhu):

What is your variants.plist? In step 5, you should have added -llvm34

What do you mean by "After a long while:" after completing step 6? Steps
5 & 6 doesn't have you do anything other than edit those files.

Step 7 has you install cctools and ld64 with the +llvm39 -llvm34 variants
explicitly specified.

So it's not clear what you are doing between step 6 and step 7 that
accounts for that "After a long while:", but you should just do step 7
after step 6 to address that error.

Disable revdep rebuild while you do this.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:10>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-11-20 09:11:05 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: jeremyhu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by snunez1):

I have just updated the sequence I followed for clarity.

The build has succeeded. The key was your comment 'disable revdep'. It
took me a while to understand what that might mean. In the end I kept
answering 'no' to any 'rev-upgrade' questions and, eventually, everything
succeeded.

It might be useful to mention this in the wiki page, or add an option to
the 'port install' command, if there is one, to disable rev-upgrade.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:11>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-11-21 00:15:45 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: kencu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------
Changes (by jeremyhu):

* owner: jeremyhu => kencu


Comment:

Over to Ken, since he's a bit more up on this than I am these days.
Sounds like the docs just need to be updated to reflect changes over the
past couple years.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:12>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-11-23 01:07:00 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+----------------------
Reporter: mrkapqa | Owner: kencu
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: | Keywords:
Port: ld64-127 |
-----------------------+----------------------

Comment (by kencu):

I think the thing to do is add a small step early in the instructions to
turn off {{{rev-upgrade}}} in {{{macports.conf}}} during the build:
{{{
revupgrade_autorun no
}}}
and then turn it back on at the end of the process.
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:13>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-12-06 00:58:16 UTC
Permalink
#56944: Error: Failed to build ld64-127: command execution failed
-----------------------+--------------------
Reporter: mrkapqa | Owner: kencu
Type: defect | Status: closed
Priority: Normal | Milestone:
Component: ports | Version: 2.5.3
Resolution: fixed | Keywords:
Port: ld64-127 |
-----------------------+--------------------
Changes (by kencu):

* status: assigned => closed
* resolution: => fixed
--
Ticket URL: <https://trac.macports.org/ticket/56944#comment:14>
MacPorts <https://www.macports.org/>
Ports system for macOS
Loading...