It would be nice to align with other components (e.g. udev, systemd, sysctl) and source config drop-ins from `/usr/lib/ld.so.conf.d/`.
This would allow distribution-provided confing drop-ins to stay in /usr. The idea behind this is that only machine-specific and user config should live in /etc, and all the distribution provided defaults live under /usr, which is read only on immutable systems. See https://0pointer.de/blog/projects/stateless.html
Right now an easy workaround is :
```
cat <<EOF > /etc/ld.so.conf.d/usr.conf
source /usr/lib/ld.so.conf.d/*.conf
EOF
```
I ran into this while trying to ship software in a systemd-sysext that required a ld config dropin. More details at https://github.com/fedora-sysexts/fedora/issues/207.
Reproducible: Always
Currently we have this in /etc/ld.so.conf:
include ld.so.conf.d/*.conf
This is a request to change it to:
include ld.so.conf.d/*.conf
include /usr/lib/ld.so.conf.d/*.conf
(Stuff like this is why I think system-wide tunables should not be configured with a separate file. With a separate file, we need to duplicate all these paths.)
Comment 2Zbigniew Jędrzejewski-Szmek
2026-07-03 12:25:48 UTC
But this still requires /etc/ld.so.conf to be present… Why not move into glibc itself
so that this kind of boilerplate file stops being necessary.
Proposal:
load automatically: /etc/ld.so.conf, /usr/lib/ld.so.conf.d/*.conf, /etc/ld.so.conf.d/*.conf
(in order of priority).
Users can use 'include' in of the files if they want to load things from other locations.