2016-03-03 13:55:55 +01:00
|
|
|
{ stdenv, lib
|
2015-12-04 22:33:02 +01:00
|
|
|
, virtualglLib
|
|
|
|
, virtualglLib_i686 ? null
|
|
|
|
}:
|
2010-07-10 10:45:44 +02:00
|
|
|
|
2016-03-03 13:55:55 +01:00
|
|
|
stdenv.mkDerivation {
|
2015-12-04 22:33:02 +01:00
|
|
|
name = "virtualgl-${lib.getVersion virtualglLib}";
|
2010-07-10 10:45:44 +02:00
|
|
|
|
2015-12-04 22:33:02 +01:00
|
|
|
paths = [ virtualglLib ];
|
2010-07-10 10:45:44 +02:00
|
|
|
|
2016-03-03 13:55:55 +01:00
|
|
|
buildCommand = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
for i in ${virtualglLib}/bin/* ${virtualglLib}/bin/.vglrun*; do
|
|
|
|
ln -s "$i" $out/bin
|
2015-12-04 22:33:02 +01:00
|
|
|
done
|
2016-03-03 13:55:55 +01:00
|
|
|
'' + lib.optionalString (virtualglLib_i686 != null) ''
|
|
|
|
ln -sf ${virtualglLib_i686}/bin/.vglrun.vars32 $out/bin
|
2010-07-13 21:12:42 +02:00
|
|
|
'';
|
2016-08-02 18:06:29 +02:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
};
|
2010-07-10 10:45:44 +02:00
|
|
|
}
|