Opened 16 months ago

Last modified 14 months ago

#63378 assigned defect

llvm-3.3: still linked against old libffi

Reported by: mrkapqa Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: toolchain Cc: jeremyhu (Jeremy Huddleston Sequoia), cooljeanius (Eric Gallager), mascguy (Christopher Nielsen)
Port: llvm

Description (last modified by kencu (Ken))

hello,

on leopard ppc 10.5.8

wget fails to build with error

Failed to build legacy-support: command execution failed

thank you

Attachments (1)

main.log (16.3 KB) - added by mrkapqa 16 months ago.

Download all attachments as: .zip

Change History (15)

Changed 16 months ago by mrkapqa

Attachment: main.log added

comment:1 Changed 16 months ago by reneeotten (Renee Otten)

Cc: cjones051073 added
Description: modified (diff)
Keywords: wget legacy-support removed
Owner: set to kencu
Port: legacy-support added; wget removed
Status: newassigned
Summary: (10.5.8) wget > Failed to build legacy-support: command execution failedlegacy-support: build failure on 10.5.8

the error appears to be

:info:build dyld: Library not loaded: /opt/local/lib/libffi.6.dylib
126	:info:build   Referenced from: /opt/local/libexec/llvm-3.3/lib/libLTO.dylib
127	:info:build   Reason: image not found
128	:info:build /usr/bin/gcc-4.2 -c -Iinclude -Os -arch ppc  src/best_fchdir.c -o src/best_fchdir.o
129	:info:build /bin/sh: line 1:   708 Trace/BPT trap          ${ld} -r "${output}.inode32.${arch}" "${output}.inode32unix2003.${arch}" "${output}.inode64unix2003.${arch}" -o "${output}.${arch}"
130	:info:build make: *** [src/fdopendir.dl.o] Error 133
131	:info:build make: *** Waiting for unfinished jobs....

comment:2 Changed 16 months ago by kencu (Ken)

Cc: cjones051073 removed
Description: modified (diff)
Keywords: wget legacy-support added
Port: wget added; legacy-support removed
Summary: legacy-support: build failure on 10.5.8(10.5.8) wget > Failed to build legacy-support: command execution failed

here is your issue:

125     :info:build dyld: Library not loaded: /opt/local/lib/libffi.6.dylib
126	:info:build   Referenced from: /opt/local/libexec/llvm-3.3/lib/libLTO.dylib
127	:info:build   Reason: image not found

I assume you have libffi installed. That was updated and the library name changed.

So - to fix this properly you'll need to rebuild llvm-3.3 against the new libffi. Uninstall llvm-3.3 and then reinstall it.

To fix this for the moment you could make a symlink from the new libffi name to the old libffi name. Just do the right fix as soon as you have a moment.

comment:3 Changed 16 months ago by kencu (Ken)

Sorry Rene, stepped on your toe. Will fix

comment:4 Changed 16 months ago by kencu (Ken)

Cc: jeremyhu added
Keywords: wget legacy-support leopard removed
Port: llvm-3.3 added; wget removed
Summary: (10.5.8) wget > Failed to build legacy-support: command execution failedllvm-3.3: still linked against old libffi

comment:5 Changed 16 months ago by kencu (Ken)

llvm-3.3 was already revbumped for the libffi update, so presumably you picked up an older version or in some way have a local disconnect.

https://github.com/macports/macports-ports/commit/12e92d7d6c63af6a3f8dda4dc950d9e446d8e64c#diff-06d014df8a437e922d5b7b5e9041dde20e3ba656b225991cdab766bc7a5a1e57

ie there is nothing to fix in the ports tree.

comment:6 Changed 15 months ago by cooljeanius (Eric Gallager)

Cc: cooljeanius added

comment:7 Changed 14 months ago by kencu (Ken)

Owner: changed from kencu to macports-tickets@…

comment:8 Changed 14 months ago by mascguy (Christopher Nielsen)

Cc: mascguy added

comment:9 Changed 14 months ago by mascguy (Christopher Nielsen)

Related ticket: issue:63443

comment:10 Changed 14 months ago by mascguy (Christopher Nielsen)

Perhaps all foundational toolchain components should be updated to reference ${prefix}/lib/libffi.dylib?

Even if it's necessary to do it after-the-fact via install_name_tool - and perhaps that would be easier than changing configure/build options - it needs to be done.

Alternatively, link against the static lib, assuming there aren't any technical barriers to doing that. Or use a different libffi port, dedicated to LLVM and friends. libffi-bootstrap perhaps?

Last edited 14 months ago by mascguy (Christopher Nielsen) (previous) (diff)

comment:11 Changed 14 months ago by Christopher Nielsen <mascguy@…>

In 6fb2ae6631b642ed4fcf13d0531348e51d29f36c/macports-ports (master):

libffi: symlink via prev major version

  • Absolutely critical, to avoid temporary toolchain breakage

Closes: #63443
Closes: #63453
See: #63378

comment:12 in reply to:  11 Changed 14 months ago by mascguy (Christopher Nielsen)

libffi: symlink via prev major version

  • Absolutely critical, to avoid temporary toolchain breakage

This fix will eliminate future carnage. However, leaving this ticket open; ultimately the toolchain needs to be insulated from our general libffi port.

Last edited 14 months ago by mascguy (Christopher Nielsen) (previous) (diff)

comment:13 Changed 14 months ago by mascguy (Christopher Nielsen)

Keywords: toolchain added
Port: llvm added; llvm-3.3 removed
Summary: llvm-3.3: still linked against old libffimacports toolchain: isolate from general libffi port, to prevent breakage on upgrade [llvm-3.3: still linked against old libffi]

comment:14 Changed 14 months ago by mascguy (Christopher Nielsen)

Summary: macports toolchain: isolate from general libffi port, to prevent breakage on upgrade [llvm-3.3: still linked against old libffi]llvm-3.3: still linked against old libffi

Folks, my apologies for muddying the waters on this. Per the insights from Josh and Ken, this isn't a big deal: Generally it's a simple matter of ports opportunistically utilizing toolchain components - particularly from cctools - without declaring a proper build dependency. But when the latter is corrected, such as with ffmpeg (issue:63443), there's no longer an issue.

Net-Net, please disregard my previous comments regarding the concern surrounding this: Yours Truly didn't have a complete understanding of the end-to-end details, and I blew this way out of proportion.

Note: See TracTickets for help on using tickets.