[MacPorts] #62426: libc++: using a newer libc++ to build software on older macos systems
MacPorts
noreply at macports.org
Wed Sep 21 16:08:28 UTC 2022
#62426: libc++: using a newer libc++ to build software on older macos systems
-------------------------------------+--------------------
Reporter: kencu | Owner: kencu
Type: enhancement | Status: closed
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: fixed | Keywords:
Port: libcxx macports-libcxx |
-------------------------------------+--------------------
Comment (by RJVB):
An example. KDevelop5 entirely rebuilt against libc++ 9.0.1 installed in
/opt/local/lib, including libc++.dylib . None of KDevelop's dependencies
are built against this libc++ version, and I don't have
DYLD_INSERT_LIBRARIES set in the environment.
{{{
> otool -L /opt/local/lib/libc++.dylib | fgrep libc++
/opt/local/lib/libc++.dylib:
/opt/local/lib/libc++.1.dylib (compatibility version 1.0.0,
current version 9.0.1)
/opt/local/lib/libc++abi.1.dylib (compatibility version 1.0.0,
current version 9.0.1)
> otool -L
/Applications/MacPorts/KF5/kdevelop.app/Contents/MacOS/kdevelop.bin |
fgrep libc++
/opt/local/lib/libc++.1.dylib (compatibility version 1.0.0,
current version 9.0.1)
> otool -L
/opt/local/libexec/qt5/Library/Frameworks/QtCore.framework/QtCore | fgrep
libc++
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current
version 120.0.0)
> env DYLD_PRINT_LIBRARIES=1
/Applications/MacPorts/KF5/kdevelop.app/Contents/MacOS/kdevelop.bin --ps
|& fgrep libc++ &
dyld: loaded: /opt/local/lib/libc++.1.dylib
dyld: loaded: /usr/lib/libc++.1.dylib
dyld: loaded: /usr/lib/libc++abi.dylib
dyld: loaded: /opt/local/lib/libc++abi.1.dylib
dyld: loaded: /usr/lib/libc++.1.dylib
dyld: loaded: /usr/lib/libc++abi.dylib
dyld: loaded: /usr/lib/libc++.1.dylib
dyld: loaded: /usr/lib/libc++abi.dylib
<snip>
> lsof +c 0 | fgrep kdevelop | fgrep libc++
kdevelop.bin 69337 bertin txt REG 1,1
2223932 9538392 /opt/local/lib/libc++.1.dylib
kdevelop.bin 69337 bertin txt REG 1,1
617328 9538394 /opt/local/lib/libc++abi.1.dylib
kdevelop.bin 76697 bertin txt REG 1,1
2223932 9538392 /opt/local/lib/libc++.1.dylib
kdevelop.bin 76697 bertin txt REG 1,1
617328 9538394 /opt/local/lib/libc++abi.1.dylib
}}}
Here I used `lsof` to obtain the files open in/by KDevelop but the open
files list given by the Activity Monitor shows the same result: only a
single version of both libc++ components is kept opened (the newest
version), despite multiple load attempts of the system versions (one for
each module/library being loaded).
--
Ticket URL: <https://trac.macports.org/ticket/62426#comment:53>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list