mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 22:20:51 +00:00
20 lines
435 B
Nix
20 lines
435 B
Nix
{ stdenv, lib
|
|
, virtualglLib
|
|
, virtualglLib_i686 ? null
|
|
}:
|
|
|
|
stdenv.mkDerivation {
|
|
name = "virtualgl-${lib.getVersion virtualglLib}";
|
|
|
|
paths = [ virtualglLib ];
|
|
|
|
buildCommand = ''
|
|
mkdir -p $out/bin
|
|
for i in ${virtualglLib}/bin/* ${virtualglLib}/bin/.vglrun*; do
|
|
ln -s "$i" $out/bin
|
|
done
|
|
'' + lib.optionalString (virtualglLib_i686 != null) ''
|
|
ln -sf ${virtualglLib_i686}/bin/.vglrun.vars32 $out/bin
|
|
'';
|
|
}
|