Opened 13 years ago
Last modified 21 months ago
#33827 reopened defect
cairo: Undefined symbols _cairo_boilerplate_get_target_by_name _cairo_boilerplate_xrealloc _cairo_boilerplate_xmalloc, and links with libraries it doesn't declare dependencies on
Reported by: | adamb2903 | Owned by: | ryandesign (Ryan Carsten Schmidt) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.0.4 |
Keywords: | Cc: | tonior@…, petr.vokac_@…, eravin@…, obartunov@…, drkp (Dan Ports), torschen@…, jowens@… | |
Port: | cairo, cairo-devel |
Description
Cairo fails to build as universal. Cleaned cairo, tried again, still nothing. Log is attached.
Attachments (4)
Change History (26)
Changed 13 years ago by adamb2903
comment:1 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Owner: | changed from macports-tickets@… to ryandesign@… |
---|---|
Port: | cairo cairo-devel added; Cairo removed |
Status: | new → assigned |
Summary: | Cairo build failure → cairo: Undefined symbols _cairo_boilerplate_get_target_by_name _cairo_boilerplate_xrealloc _cairo_boilerplate_xmalloc |
comment:4 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | eravin@… added |
---|---|
Summary: | cairo: Undefined symbols _cairo_boilerplate_get_target_by_name _cairo_boilerplate_xrealloc _cairo_boilerplate_xmalloc → cairo tries to link with libraries it doesn't declare dependencies on |
Has duplicate #33856.
comment:5 Changed 13 years ago by obartunov@…
Replying to adam.bartley@…:
Cairo fails to build as universal. Cleaned cairo, tried again, still nothing. Log is attached.
I got the same problem, when did 'port upgrade outdated' two days ago on my mba running Lion. Any hope to resolve this problem ?
comment:6 follow-up: 7 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | obartunov@… added |
---|
You can work around the problem by deactivating the implicated ports for the duration of the cairo build. For example, if the cairo log says "ignoring file /opt/local/lib/libspectre.dylib, file was built for unsupported file format which is not the architecture being linked", then you can use "port provides /opt/local/lib/libspectre.dylib" to discover that this library was provided by the "libspectre" port. You can then "sudo port -f deactivate libspectre", "sudo port clean cairo" and try again. You may have to do this for multiple implicated ports. Once you get cairo installed, you can "sudo port activate libspectre" again (and similarly for other ports you deactivated) if desired.
comment:7 Changed 13 years ago by obartunov@…
Replying to ryandesign@…:
You can work around the problem by deactivating the implicated ports for the duration of the cairo build. For example, if the cairo log says "ignoring file /opt/local/lib/libspectre.dylib, file was built for unsupported file format which is not the architecture being linked", then you can use "port provides /opt/local/lib/libspectre.dylib" to discover that this library was provided by the "libspectre" port. You can then "sudo port -f deactivate libspectre", "sudo port clean cairo" and try again. You may have to do this for multiple implicated ports. Once you get cairo installed, you can "sudo port activate libspectre" again (and similarly for other ports you deactivated) if desired.
I don't understand this. I tried to install ufraw and port requires upgrade cairo. Buildig cairo fails with
clang: warning: argument unused during compilation: '-Wp,-D_FORTIFY_SOURCE=2' Undefined symbols for architecture x86_64: "_cairo_boilerplate_get_target_by_name", referenced from: _main in cairo_sphinx-sphinx.o "_cairo_boilerplate_xrealloc", referenced from: _main in cairo_sphinx-sphinx.o _recorder in lto.o "_cairo_boilerplate_xmalloc", referenced from: _main in cairo_sphinx-sphinx.o __surface_create in lto.o __context_create in lto.o _get_surface_size in lto.o _recorder in lto.o ld: symbol(s) not found for architecture x86_64
I attached main.log. What should i deactivate ?
comment:8 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
obartunov, that doesn't look like the same error being discussed in this ticket.
comment:9 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Actually never mind, I see it is the same error adam.bartley reported. Well I don't know if it's related to cairo using undeclared dependencies. We may have multiple unrelated problems occurring.
comment:12 Changed 13 years ago by macports@…
Ran into this when trying to upgrade all. Goes until:
:info:build any2ppm.c:72:26: error: librsvg/rsvg.h: No such file or directory :info:build any2ppm.c:73:32: error: librsvg/rsvg-cairo.h: No such file or directory
Then it is nothing but errors. Attaching log.
Changed 13 years ago by macports@…
Attachment: | cairo.main.log added |
---|
comment:13 Changed 13 years ago by macports@…
Temporarily deactivating librsvg allowed cairo to build successfully, as suggested.
comment:15 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
- r91883: prevent use of ghostscript
comment:16 follow-up: 17 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
- r91886: prevent use of librsvg, libspectre, poppler
comment:17 Changed 13 years ago by torschen@…
Resolution: | fixed |
---|---|
Status: | closed → reopened |
sorry, but these changes did not solve the problem for me. I did a port selfupdate, port clean cairo, port install cairo and still get the same error as before:
:info:build Undefined symbols for architecture x86_64: :info:build "_cairo_boilerplate_get_target_by_name", referenced from: :info:build _main in cairo_sphinx-sphinx.o :info:build "_cairo_boilerplate_xrealloc", referenced from: :info:build _main in cairo_sphinx-sphinx.o :info:build _recorder in lto.o :info:build "_cairo_boilerplate_xmalloc", referenced from: :info:build _main in cairo_sphinx-sphinx.o :info:build __surface_create in lto.o :info:build __context_create in lto.o :info:build _get_surface_size in lto.o :info:build _recorder in lto.o :info:build ld: symbol(s) not found for architecture x86_64 :info:build clang: error: linker command failed with exit code 1 (use -v to see invocation)
Log is attached.
Changed 13 years ago by torschen@…
Attachment: | main.3.log added |
---|
comment:18 follow-up: 19 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Summary: | cairo tries to link with libraries it doesn't declare dependencies on → cairo: Undefined symbols _cairo_boilerplate_get_target_by_name _cairo_boilerplate_xrealloc _cairo_boilerplate_xmalloc, and links with libraries it doesn't declare dependencies on |
---|
Ok, then I apologize for putting the unrelated problem "cairo links with libraries it doesn't declare dependencies on" into this ticket; it should have been its own ticket.
I'll now have to ask the cairo developers about this undefined boilerplate symbols problem.
comment:19 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Replying to ryandesign@…:
I'll now have to ask the cairo developers about this undefined boilerplate symbols problem.
Asked. As a workaround, I suggest you try using a different compiler.
the unrelated problem "cairo links with libraries it doesn't declare dependencies on" into this ticket [...] should have been its own ticket.
For the record, I asked about this on the cairo mailing list too. If a better solution than the patch I implemented emerges, we can still update the port.
comment:20 Changed 13 years ago by torschen@…
great, that worked. Using
sudo port install cairo configure.compiler=llvm-gcc-4.2
under Mac OS Lion solved the problem for me. Thank you very much.
comment:21 Changed 12 years ago by jmroot (Joshua Root)
Have you checked if it just needs gnu89 inline semantics?
comment:22 Changed 5 years ago by jmroot (Joshua Root)
This ticket seems to be about multiple issues, so it's hard to tell if it's resolved. Building cairo universal doesn't seem to be a problem any more at least.
I already know cairo will link with some libraries I didn't expect it to use. I'll fix that, then we'll see whether anything additional needs to be done for this issue.