more generic way. Still, there is a lot of room for improvement. svn path=/nixpkgs/trunk/; revision=4458
svn path=/nixpkgs/trunk/; revision=4214