[MacPorts] #20889: llvm-gcc42: installs libgcc_s.1.dylib in ${prefix}/lib
MacPorts
noreply at macports.org
Sat Aug 29 05:35:46 PDT 2009
#20889: llvm-gcc42: installs libgcc_s.1.dylib in ${prefix}/lib
-------------------------------------+--------------------------------------
Reporter: ryandesign@… | Owner: erickt@…
Type: defect | Status: new
Priority: High | Milestone:
Component: ports | Version: 1.7.1
Keywords: | Port: llvm-gcc42
-------------------------------------+--------------------------------------
llvm-gcc42 installs the file libgcc_s.1.dylib in ${prefix}/lib. This is a
problem because any port that builds with gcc (i.e. most ports) links with
libgcc_s.1.dylib -- supposed to be linking with the copy provided by
Apple's gcc in /usr/lib but if llvm-gcc42 is installed it links with llvm-
gcc42's version instead. This makes it basically impossible to remove
llvm-gcc42 once it's been installed and other ports have subsequently been
built.
{{{
$ port install zlib
...
$ otool -L /opt/local/lib/libz.dylib
/opt/local/lib/libz.dylib:
/opt/local/lib/libz.1.dylib (compatibility version 1.0.0, current
version 1.2.3)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current
version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 111.1.4)
$ port install llvm-gcc42
...
$ port contents llvm-gcc42 | grep libgcc.*dylib
/opt/local/lib/libgcc_s.1.dylib
/opt/local/lib/libgcc_s.10.4.dylib
/opt/local/lib/libgcc_s.10.5.dylib
/opt/local/lib/libgcc_s_ppc64.1.dylib
/opt/local/lib/libgcc_s_x86_64.1.dylib
$ port -nf upgrade zlib
...
$ otool -L /opt/local/lib/libz.dylib
/opt/local/lib/libz.dylib:
/opt/local/lib/libz.1.dylib (compatibility version 1.0.0, current
version 1.2.3)
/opt/local/lib/libgcc_s.1.dylib (compatibility version 1.0.0,
current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 111.1.4)
}}}
It is wrong for ports (e.g. zlib) to make use of other ports (e.g. llvm-
gcc42) that they haven't declared dependencies on. But it's not
appropriate to modify every other port in the tree to either depend on
llvm-gcc42 or work around this issue. Rather, llvm-gcc42 should install
its libraries in a different place. Perhaps look at how the gcc4* ports
handle this.
--
Ticket URL: <http://trac.macports.org/ticket/20889>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list