On Thu, Jan 20, 2011 at 10:47 AM, Rolf Eike Beer <span dir="ltr"><<a href="mailto:eike@sf-mail.de" target="_blank">eike@sf-mail.de</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div>> On Thursday 20 January 2011, James Bigler wrote:<br>
> > I'm noticing that on some systems they package the NVIDIA driver into<br>
> > different directories than the driver is typically installed. In<br>
> > order to make stuff link properly at run time these non-standard<br>
> > locations are added to /etc/ld.so.conf.d. I'm wondering if there is a<br>
> > reason not to use this information to add paths to<br>
> > CMAKE_SYSTEM_LIBRARY_PATH? It would certainly help in finding<br>
> > libraries that are installed in diverse places.<br>
><br>
> Sounds like a useful idea IMO.<br>
> It could be done in UnixPaths.cmake, if /etc/ld.so.conf exists, parse<br>
> it, get the directories from it, check for duplicates, and add them to<br>
> the search paths.<br>
<br>
</div>Sounds indeed sane. But be aware that this file may contain include directives with glob expressions, usually something like /etc/ld.so.conf.d/*.conf. If you don't follow them you will hardly find anything on modern distros.<br>
<br>
Eike<br>
<br></blockquote><div><br>Yeah, the one I'm looking at looks like this:<br><br>$ cat ld.so.conf<br>include /etc/ld.so.conf.d/*.conf<br>/usr/local/lib<br><br>$ for T in ld.so.conf.d/*;do echo $T; cat $T;done<br>ld.so.conf.d/R-i386.conf<br>
/usr/lib/R/lib<br>ld.so.conf.d/atlas-i386.conf<br>/usr/lib/atlas<br>ld.so.conf.d/cuda-%{arch}.conf<br>/usr/lib/cuda<br>ld.so.conf.d/kernel-2.6.35.10-69.fc14.i686.PAE.conf<br># Placeholder file, no vDSO hwcap entries used in this kernel.<br>
ld.so.conf.d/kernel-2.6.35.10-72.fc14.i686.PAE.conf<br># Placeholder file, no vDSO hwcap entries used in this kernel.<br>ld.so.conf.d/kernel-2.6.35.10-74.fc14.i686.PAE.conf<br># Placeholder file, no vDSO hwcap entries used in this kernel.<br>
ld.so.conf.d/mysql-i386.conf<br>/usr/lib/mysql<br>ld.so.conf.d/nvidia-lib.conf<br>/usr/lib/nvidia<br>ld.so.conf.d/octave-i386.conf<br>/usr/lib/octave-3.3.54<br>ld.so.conf.d/qt-i386.conf<br>/usr/lib/qt-3.3/lib<br>ld.so.conf.d/tix-i386.conf<br>
/usr/lib/tcl8.5<br>ld.so.conf.d/wine-32.conf<br>/usr/lib/wine/<br>ld.so.conf.d/xulrunner-32.conf<br>/usr/lib/xulrunner-1.9.2<br>ld.so.conf.d/xulrunner2-32.conf<br>/usr/lib/xulrunner-2<br><br></div></div>