manpath change for ports ?

Tijl Coosemans tijl at FreeBSD.org
Fri Mar 10 11:38:59 UTC 2017


On Thu, 9 Mar 2017 19:43:05 -0600 Benjamin Kaduk <kaduk at mit.edu> wrote:
> On Thu, Mar 09, 2017 at 12:35:32PM +0100, Tijl Coosemans wrote:
>> Note that -rpath /usr/local/lib isn't added by gcc but by libtool
>> because it assumes rtld will not search that directory automatically.
>> If you run './configure CC=gcc --prefix=/usr && make check' the tests
>> should succeed (without --enable-new-dtags) because -rpath isn't used
>> then.  
> 
> Sounds like a bug in the libtool packaging, then?

Rtld only searches /lib and /usr/lib.  It also searches the ldconfig
hints file and /usr/local/lib is there by default (ldconfig_paths in
/etc/defaults/rc.conf), but users are allowed to change that, for
instance when they install ports in another location than /usr/local.

Arguably, because our default compiler links with --enable-new-dtags,
gcc should as well, but because of the different run-time semantics of
DT_RPATH and DT_RUNPATH this is a potential minefield.  Upstream
binutils changed the default in ld once and this was quickly reverted.


More information about the freebsd-ports mailing list