Merge pull request #47455 from nyanloutre/steamPackages.steam-udev
steamPackages.steam: add udev rules and update to 1.0.0.56
This commit is contained in:
commit
bc0d87a4f1
@ -413,11 +413,8 @@ packageOverrides = pkgs: {
|
|||||||
in your <filename>/etc/nixos/configuration.nix</filename>. You'll also need
|
in your <filename>/etc/nixos/configuration.nix</filename>. You'll also need
|
||||||
<programlisting>hardware.pulseaudio.support32Bit = true;</programlisting>
|
<programlisting>hardware.pulseaudio.support32Bit = true;</programlisting>
|
||||||
if you are using PulseAudio - this will enable 32bit ALSA apps integration.
|
if you are using PulseAudio - this will enable 32bit ALSA apps integration.
|
||||||
To use the Steam controller, you need to add
|
To use the Steam controller or other Steam supported controllers such as the DualShock 4 or Nintendo Switch Pro, you need to add
|
||||||
<programlisting>services.udev.extraRules = ''
|
<programlisting>hardware.steam-hardware.enable = true;</programlisting>
|
||||||
SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0666"
|
|
||||||
KERNEL=="uinput", MODE="0660", GROUP="users", OPTIONS+="static_node=uinput"
|
|
||||||
'';</programlisting>
|
|
||||||
to your configuration.
|
to your configuration.
|
||||||
</para>
|
</para>
|
||||||
</section>
|
</section>
|
||||||
|
25
nixos/modules/hardware/steam-hardware.nix
Normal file
25
nixos/modules/hardware/steam-hardware.nix
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
|
||||||
|
cfg = config.hardware.steam-hardware;
|
||||||
|
|
||||||
|
in
|
||||||
|
|
||||||
|
{
|
||||||
|
options.hardware.steam-hardware = {
|
||||||
|
enable = mkOption {
|
||||||
|
type = types.bool;
|
||||||
|
default = false;
|
||||||
|
description = "Enable udev rules for Steam hardware such as the Steam Controller, other supported controllers and the HTC Vive";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
services.udev.packages = [
|
||||||
|
pkgs.steamPackages.steam
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
@ -46,6 +46,7 @@
|
|||||||
./hardware/opengl.nix
|
./hardware/opengl.nix
|
||||||
./hardware/pcmcia.nix
|
./hardware/pcmcia.nix
|
||||||
./hardware/raid/hpsa.nix
|
./hardware/raid/hpsa.nix
|
||||||
|
./hardware/steam-hardware.nix
|
||||||
./hardware/usb-wwan.nix
|
./hardware/usb-wwan.nix
|
||||||
./hardware/onlykey.nix
|
./hardware/onlykey.nix
|
||||||
./hardware/video/amdgpu.nix
|
./hardware/video/amdgpu.nix
|
||||||
|
@ -2,14 +2,14 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
traceLog = "/tmp/steam-trace-dependencies.log";
|
traceLog = "/tmp/steam-trace-dependencies.log";
|
||||||
version = "1.0.0.51";
|
version = "1.0.0.56";
|
||||||
|
|
||||||
in stdenv.mkDerivation rec {
|
in stdenv.mkDerivation rec {
|
||||||
name = "steam-original-${version}";
|
name = "steam-original-${version}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://repo.steampowered.com/steam/pool/steam/s/steam/steam_${version}.tar.gz";
|
url = "http://repo.steampowered.com/steam/pool/steam/s/steam/steam_${version}.tar.gz";
|
||||||
sha256 = "1ghrfznm9rckm8v87zvh7hx820r5pp7sq575wxwq0fncbyq6sxmz";
|
sha256 = "01jgp909biqf4rr56kb08jkl7g5xql6r2g4ch6lc71njgcsbn5fs";
|
||||||
};
|
};
|
||||||
|
|
||||||
makeFlags = [ "DESTDIR=$(out)" "PREFIX=" ];
|
makeFlags = [ "DESTDIR=$(out)" "PREFIX=" ];
|
||||||
@ -25,6 +25,8 @@ in stdenv.mkDerivation rec {
|
|||||||
EOF
|
EOF
|
||||||
chmod +x $out/bin/steamdeps
|
chmod +x $out/bin/steamdeps
|
||||||
''}
|
''}
|
||||||
|
install -d $out/lib/udev/rules.d
|
||||||
|
install -m644 lib/udev/rules.d/*.rules $out/lib/udev/rules.d
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user