410f21887a
in /usr/lib/libGL.so.1 (which will typically load a driver in /usr/X11R6/lib/modules/dri). This has been tested on a i915 graphics card; it should work with most open source X.org drivers. For NVidia's proprietary drivers (which we cannot build ourselves anyway), some more symlinks are necessary; I'll add those later. So to get hardware-accelerated Quake 3, do: $ nix-env -p /nix/var/nix/profiles/opengl -i xorg-sys-opengl $ nix-env -i quake3-demo $ quake3 svn path=/nixpkgs/trunk/; revision=4613
16 lines
489 B
Nix
16 lines
489 B
Nix
# This is a very dirty hack to allow hardware acceleration of OpenGL
|
|
# applications for most (?) users. It will use the driver that your
|
|
# Linux distribution installed in /usr/lib/libGL.so.1. Hopefully,
|
|
# this driver uses hardware acceleration.
|
|
#
|
|
# Of course, use of the driver in /usr/lib is highly impure. But it
|
|
# might actually work ;-)
|
|
|
|
{stdenv, xlibs, expat}:
|
|
|
|
stdenv.mkDerivation {
|
|
name = "xorg-sys-opengl";
|
|
builder = ./builder.sh;
|
|
neededLibs = [xlibs.libXxf86vm expat];
|
|
}
|