Idea by Eelco, initial patch by Jack Cummings, minor fixups by me svn path=/nixpkgs/branches/stdenv-updates/; revision=33741