I have recently installed a fresh gentoo linux setup. When installing the nVidia drivers according to the instructions on the web-site, I encountered problems getting OpenGL programs to run correctly. glxinfo returned "Direct rendering: no", frame rate was bad and some programs wouldn't run. Great help from people at #gentoo-irc and a "ldd -d glxgears" revealed that the libGL.so drivers used by the applications were the ones that come with XFree86. ld loaded the drivers from /usr/lib, and there were symlinks to /usr/X11R6/lib/libGL.so from there. I noticed from the ebuilds that it was made a point to put /opt/nvidia/lib before /usr/X11R6/lib in ld.so.conf to avoid this problem, but as (to my knowledge at least) ld loads by default from /usr/lib first even though /usr/lib isn't listed in ld.so.conf, there are still issues with the default setup. To get around the problem I changed the libGL-symlinks in /usr/lib to point to the nVidia provided ones, and all problems were resolved. Another solution (and prehaps better) might be to remove the libGL-symlinks in /usr/lib alltogether, so that control over which drivers is loaded can be reestablished in ld.so.conf. Best regards Martin Blix Grydeland
Fixed from xfree-4.2.0-r9 and nvidia-*-1.0.2880