nixpkgs/pkgs/misc/drivers/sc-controller/default.nix
Ryan Mulligan ba5b0a5f59 sc-controller: 0.4.0.1 -> 0.4.0.2
Semi-automatic update. These checks were performed:

- built on NixOS
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/sc-controller -h` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/sc-controller --help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/sc-controller -V` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/sc-controller --version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc -h` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc --help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc -V` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc --version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc -h` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc --help` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc help` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc-daemon -h` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/scc-daemon --help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped -h` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped --help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped -V` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped --version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped -h` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped --help` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/..scc-wrapped-wrapped help` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped -h` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped --help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped help` got 0 exit code
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped -V` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped --version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped version` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped -h` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped --help` and found version 0.4.0.2
- ran `/nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2/bin/.scc-wrapped help` and found version 0.4.0.2
- found 0.4.0.2 with grep in /nix/store/yjhdx3zx9zivz9x2wl2z0c5kqv8b5hkv-sc-controller-0.4.0.2

cc "@orivej"
2018-02-28 11:31:29 +01:00

62 lines
1.8 KiB
Nix

{ lib, buildPythonApplication, fetchFromGitHub, wrapGAppsHook
, gtk3, gobjectIntrospection, libappindicator-gtk3, librsvg
, evdev, pygobject3, pylibacl, pytest
, linuxHeaders
, libX11, libXext, libXfixes, libusb1
}:
buildPythonApplication rec {
pname = "sc-controller";
version = "0.4.0.2";
src = fetchFromGitHub {
owner = "kozec";
repo = "sc-controller";
rev = "v${version}";
sha256 = "0v1fgmnsi70z52l6c3fg49vki5rrdswr38mc82wbpmgi68vxwnyy";
};
nativeBuildInputs = [ wrapGAppsHook ];
buildInputs = [ gtk3 gobjectIntrospection libappindicator-gtk3 librsvg ];
propagatedBuildInputs = [ evdev pygobject3 pylibacl ];
checkInputs = [ pytest ];
postPatch = ''
substituteInPlace scc/paths.py --replace sys.prefix "'$out'"
substituteInPlace scc/uinput.py --replace /usr/include ${linuxHeaders}/include
'';
LD_LIBRARY_PATH = lib.makeLibraryPath [ libX11 libXext libXfixes libusb1 ];
preFixup = ''
gappsWrapperArgs+=(--prefix LD_LIBRARY_PATH : "$LD_LIBRARY_PATH")
# gdk-pixbuf setup hook can not choose between propagated librsvg
# and our librsvg with GObject introspection.
GDK_PIXBUF_MODULE_FILE=$(echo ${librsvg}/lib/gdk-pixbuf-2.0/*/loaders.cache)
'';
postFixup = ''
(
# scc runs these scripts as programs. (See find_binary() in scc/tools.py.)
cd $out/lib/python*/site-packages/scc/x11
patchPythonScript scc-autoswitch-daemon.py
patchPythonScript scc-osd-daemon.py
)
'';
checkPhase = ''
PYTHONPATH=. py.test
'';
meta = with lib; {
homepage = https://github.com/kozec/sc-controller;
# donations: https://www.patreon.com/kozec
description = "User-mode driver and GUI for Steam Controller and other controllers";
license = licenses.gpl2;
platforms = platforms.linux;
maintainers = [ maintainers.orivej ];
};
}