Don't rely on questionable impact of DT_RPATH on dlopen().
This is a bit of a messy subject, but probably the clearest
reference to motivate *not* relying on how dlopen() behaves
in the presence of RPATH or RUNPATH is the following:
https://sourceware.org/ml/libc-hacker/2002-11/msg00011.html
FWIW the dlopen() manpage only mentions the the RPATH
and RUNPATH in the "executable file for the calling program";
no mention of the executable files for libraries--
this has been brought to the attention of the relevant
parties and AFAICT nothing has been done.
The best reference for glibc behavior is
apparently to ... "try it and see".
Luckily a generous soul did exactly that
and reported the findings:
https://www.spinics.net/lists/linux-man/msg02291.html
Qt wrote on the subject a bit when they were bit by this,
linking to the above articles (directly or indirectly).
See:
http://blog.qt.io/blog/2011/10/28/rpath-and-runpath/
--------
Since we know the path of libGL at build-time for libepoxy,
there's a simple solution we can use to avoid all of this:
simply teach libepoxy to explicitly look in the libGL path.
This commit patches libepoxy to accomplish this,
looking to "LIBGL_PATH" as a fallback if it cannot find
the libraries otherwise.
---------
This fixes use of libepoxy w/musl on NixOS!
Semi-automatic update generated by https://github.com/ryantm/nix-update tools. These checks were done:
- built on NixOS
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/.thg-wrapped -h` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/.thg-wrapped --help` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/.thg-wrapped help` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/.thg-wrapped version` and found version 4.5.2
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/thg -h` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/thg --help` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/thg help` got 0 exit code
- ran `/nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2/bin/thg version` and found version 4.5.2
- found 4.5.2 with grep in /nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2
- found 4.5.2 in filename of file in /nix/store/zffgxhajwm899w5ybwhr35j16xbx6lh7-tortoisehg-4.5.2
Semi-automatic update generated by https://github.com/ryantm/nix-update tools. These checks were done:
- built on NixOS
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/hg -h` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/hg --help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/hg help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/hg --version` and found version 4.5.2
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/hg version` and found version 4.5.2
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/..hg-wrapped-wrapped -h` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/..hg-wrapped-wrapped --help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/..hg-wrapped-wrapped help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/..hg-wrapped-wrapped --version` and found version 4.5.2
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/..hg-wrapped-wrapped version` and found version 4.5.2
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/.hg-wrapped -h` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/.hg-wrapped --help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/.hg-wrapped help` got 0 exit code
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/.hg-wrapped --version` and found version 4.5.2
- ran `/nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2/bin/.hg-wrapped version` and found version 4.5.2
- found 4.5.2 with grep in /nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2
- found 4.5.2 in filename of file in /nix/store/vr3mxrjhmmpqydkd69z3fdc7qjdsafgz-mercurial-4.5.2
- directory tree listing: https://gist.github.com/7a681b5af1e240918913ffd718e9b3e9
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/zziplib/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzcat -h` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzcat --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzcat help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzcat --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzdir --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzdir --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcat -h` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcat --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcat help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcat --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxordir -h` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxordir --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxordir --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcopy -h` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcopy --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/zzxorcopy --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip -v` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mix --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mix -v` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mix --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mem --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mem -v` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-mem --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-big --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-big -v` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzzip-big --version` and found version 0.13.69
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzip-mem -h` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzip-mem --help` got 0 exit code
- ran `/nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69/bin/unzip-mem --version` and found version 0.13.69
- found 0.13.69 with grep in /nix/store/9lh4yxh3lq6mv354jvbd3gqjv4dha740-zziplib-0.13.69
- directory tree listing: https://gist.github.com/fec112f9114c98b118a59917224af5ff
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/vim/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/j6w96w36f0naab7fffqri1cmspaa3mnb-vim-8.0.1655/bin/vim -h` got 0 exit code
- ran `/nix/store/j6w96w36f0naab7fffqri1cmspaa3mnb-vim-8.0.1655/bin/vim --help` got 0 exit code
- ran `/nix/store/j6w96w36f0naab7fffqri1cmspaa3mnb-vim-8.0.1655/bin/vim --version` and found version 8.0.1655
- found 8.0.1655 with grep in /nix/store/j6w96w36f0naab7fffqri1cmspaa3mnb-vim-8.0.1655
- directory tree listing: https://gist.github.com/b65f9cb4045c205c8c3ee68503c42596
This is only needed if built from the source repository, since we are
using the release tarball the generated manpage is included. This
removes the "wild" dependency on ruby very deep in the dependency tree.
(util-linux -> systemd -> libidn2 -> ronn -> ruby)
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/lyx/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/lyxclient -h` got 0 exit code
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx -h` got 0 exit code
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx --help` got 0 exit code
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx -v` and found version 2.3.0
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx --version` and found version 2.3.0
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx -h` and found version 2.3.0
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/tex2lyx --help` and found version 2.3.0
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/.lyx-wrapped --help` got 0 exit code
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/.lyx-wrapped --version` and found version 2.3.0
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/lyx --help` got 0 exit code
- ran `/nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0/bin/lyx --version` and found version 2.3.0
- found 2.3.0 with grep in /nix/store/p9561m3hhl936qh6wc3zhaypz9axywar-lyx-2.3.0
- directory tree listing: https://gist.github.com/446d7f60ddce2b781c23ff41a2d673d1
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/txt2man/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/src2man -h` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/src2man --help` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/bookman -h` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/bookman --help` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/txt2man -h` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/txt2man --help` got 0 exit code
- ran `/nix/store/vydx2fidxsxrqm9kanw76gbb8fp4imaz-txt2man-1.6.0/bin/txt2man help` got 0 exit code
- directory tree listing: https://gist.github.com/ae0f9873f1dd72fc8e50875212ed15b3
Semi-automatic update generated by https://github.com/ryantm/nix-update tools.
This update was made based on information from https://repology.org/metapackage/spectre-meltdown-checker/versions.
These checks were done:
- built on NixOS
- ran `/nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36/bin/spectre-meltdown-checker -h` got 0 exit code
- ran `/nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36/bin/spectre-meltdown-checker --help` got 0 exit code
- ran `/nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36/bin/spectre-meltdown-checker --version` and found version 0.36
- ran `/nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36/bin/spectre-meltdown-checker -h` and found version 0.36
- ran `/nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36/bin/spectre-meltdown-checker --help` and found version 0.36
- found 0.36 with grep in /nix/store/7lrw74lhzrxf9qlykxbq0z4zqick818s-spectre-meltdown-checker-0.36
- directory tree listing: https://gist.github.com/ecf768a2a6ae0c7389c9248d2e0b98dc
So far, `mkValueString` defaulted to `toString`,
which is a bad match for most configuration file formats,
especially because how booleans are formatted.
This also improves error messages for unsupported types.
Add a test to codify the formatting.