Opened 12 years ago
Closed 12 years ago
#37868 closed defect (fixed)
qt4-mac: ld: library not found for -ldbus-1
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | michaelld (Michael Dickens) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.1.2 |
Keywords: | Cc: | ||
Port: | qt4-mac |
Description
qt4-mac fails to build on my Lion machine with Xcode 4.3.3.
ld: library not found for -ldbus-1
$ clang -v Apple clang version 3.1 (tags/Apple/clang-318.0.61) (based on LLVM 3.1svn) Target: x86_64-apple-darwin11.4.2 Thread model: posix
I suspect the problem is because this version of clang does not honor CPATH or LIBRARY_PATH.
If you don't have access to a machine with Lion and Xcode 4.3 to test with, you can also reproduce the problem by using MacPorts clang-2.9 or 3.0 which experience the same issue.
sudo port build qt4-mac configure.compiler=macports-clang-3.0
If it's too difficult to fix qt4-mac to properly find dbus without CPATH and LIBRARY_PATH, you could use the compiler_blacklist_versions portgroup to blacklist these old versions of clang.
Attachments (1)
Change History (3)
Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Attachment: | main.log.bz2 added |
---|
comment:1 Changed 12 years ago by michaelld (Michael Dickens)
comment:2 Changed 12 years ago by michaelld (Michael Dickens)
Resolution: | → fixed |
---|---|
Status: | new → closed |
Fixed in r102344. I added a configure check for LIBRARY_PATH, so hopefully tickets such as this one related to not using a supported compiler for building qt4-mac will be easier to understand and fix (and, faster to detect for end users).
In my (limited) testing, macports-clang-3.0 honors CPATH, but 2.9 does not; the issue here is I think really with LIBRARY_PATH. I'm already blacklisting Apple clang 318.0.58 and older for this reason (and, other compilers for other reasons); so, it seems like I need to bump this up to 318.0.61 . Or, as you say, figure out how to not use CPATH and LIBRARY_PATH. I just added configure tests for CPATH and others, but did not include LIBRARY_PATH. I'll add another test for that one too (seems like a wise idea; do not compile using a non-blacklisted compiler if it does not support the necessary options).