steamPackages.steam: add udev rules

This commit is contained in:
Jonathan Ringer 2020-12-23 08:54:18 -08:00 committed by Jonathan Ringer
parent e24bf9062b
commit 9721604610

View file

@ -1,4 +1,4 @@
{stdenv, fetchurl, runtimeShell, traceDeps ? false}:
{ stdenv, fetchurl, runtimeShell, traceDeps ? false, bash }:
let
traceLog = "/tmp/steam-trace-dependencies.log";
@ -27,6 +27,12 @@ in stdenv.mkDerivation {
chmod +x $out/bin/steamdeps
''}
# install udev rules
mkdir -p $out/etc/udev/rules.d/
cp ./subprojects/steam-devices/*.rules $out/etc/udev/rules.d/
substituteInPlace $out/etc/udev/rules.d/60-steam-input.rules \
--replace "/bin/sh" "${bash}/bin/bash"
# this just installs a link, "steam.desktop -> /lib/steam/steam.desktop"
rm $out/share/applications/steam.desktop
sed -e 's,/usr/bin/steam,steam,g' steam.desktop > $out/share/applications/steam.desktop