git.iko.soy/typeable/nixpkgs
on master help sign in
lutris: 0.5.9.1 -> 0.5.10
commit459d04132d0398b175b3915d3e4e3eb2adf1eb3e authorSolene Rapenne <solene@perso.pw> dateSat 2 Apr 2022, 22:22 (5 years ago) parent117fe1f
2 files changed+12−77
pkgs/applications/misc/lutris/default.nix+12−10 pkgs/applications/misc/lutris/fixes.patch−67
pkgs/applications/misc/lutris/default.nix+12−10
@@ -4,6 +4,7 @@
44
55 # build inputs
66, atk
7+, file
78, gdk-pixbuf
89, glib-networking
910, gnome-desktop
@@ -17,7 +18,7 @@
1718
1819 # check inputs
1920, xvfb-run
20−, nose
21+, nose2
2122, flake8
2223
2324 # python dependencies
@@ -83,13 +84,13 @@ let
8384in
8485buildPythonApplication rec {
8586 pname = "lutris-original";
86− version = "0.5.9.1";
87+ version = "0.5.10";
8788
8889 src = fetchFromGitHub {
8990 owner = "lutris";
9091 repo = "lutris";
9192 rev = "v${version}";
92− sha256 = "sha256-ykPJneCKbFKv0x/EDo9PkRb1LkMeFeYzTDmvE3ShNe0=";
93+ sha256 = "sha256-PrnULCdQXNZ9OTa00NVyqiTdKRRkAYBcDj7lMwEqkw4=";
9394 };
9495
9596 nativeBuildInputs = [ wrapGAppsHook ];
@@ -103,6 +104,7 @@ buildPythonApplication rec {
103104 libnotify
104105 pango
105106 webkitgtk
107+ python_magic
106108 ] ++ gstDeps;
107109
108110 propagatedBuildInputs = [
@@ -118,7 +120,13 @@ buildPythonApplication rec {
118120 python_magic
119121 ];
120122
121− checkInputs = [ xvfb-run nose flake8 ] ++ requiredTools;
123+ postPatch = ''
124+ substituteInPlace lutris/util/magic.py \
125+ --replace "'libmagic.so.1'" "'${lib.getLib file}/lib/libmagic.so.1'"
126+ '';
127+
128+
129+ checkInputs = [ xvfb-run nose2 flake8 ] ++ requiredTools;
122130 preCheck = "export HOME=$PWD";
123131 checkPhase = ''
124132 runHook preCheck
@@ -126,12 +134,6 @@ buildPythonApplication rec {
126134 runHook postCheck
127135 '';
128136
129− # unhardcodes xrandr and fixes nosetests
130− # upstream in progress: https://github.com/lutris/lutris/pull/3754
131− patches = [
132− ./fixes.patch
133− ];
134−
135137 # avoid double wrapping
136138 dontWrapGApps = true;
137139 makeWrapperArgs = [
pkgs/applications/misc/lutris/fixes.patchdeleted−67
@@ -1,67 +0,0 @@
1−diff --git a/Makefile b/Makefile
2−index 821a9500..75affa77 100644
3−--- a/Makefile
4−+++ b/Makefile
5−@@ -25,12 +25,12 @@ release: build-source upload upload-ppa
6−
7− test:
8− rm tests/fixtures/pga.db -f
9−- nosetests3
10−+ nosetests
11−
12− cover:
13− rm tests/fixtures/pga.db -f
14− rm tests/coverage/ -rf
15−- nosetests3 --with-coverage --cover-package=lutris --cover-html --cover-html-dir=tests/coverage
16−+ nosetests --with-coverage --cover-package=lutris --cover-html --cover-html-dir=tests/coverage
17−
18− pgp-renew:
19− osc signkey --extend home:strycore
20−diff --git a/lutris/util/graphics/xrandr.py b/lutris/util/graphics/xrandr.py
21−index f788c94c..5544dbe9 100644
22−--- a/lutris/util/graphics/xrandr.py
23−+++ b/lutris/util/graphics/xrandr.py
24−@@ -5,6 +5,7 @@ from collections import namedtuple
25−
26− from lutris.util.log import logger
27− from lutris.util.system import read_process_output
28−+from lutris.util.linux import LINUX_SYSTEM
29−
30− Output = namedtuple("Output", ("name", "mode", "position", "rotation", "primary", "rate"))
31−
32−@@ -12,7 +13,7 @@ Output = namedtuple("Output", ("name", "mode", "position", "rotation", "primary"
33− def _get_vidmodes():
34− """Return video modes from XrandR"""
35− logger.debug("Retrieving video modes from XrandR")
36−- return read_process_output(["xrandr"]).split("\n")
37−+ return read_process_output([LINUX_SYSTEM.get("xrandr")]).split("\n")
38−
39−
40− def get_outputs(): # pylint: disable=too-many-locals
41−@@ -76,7 +77,7 @@ def turn_off_except(display):
42− for output in get_outputs():
43− if output.name != display:
44− logger.info("Turning off %s", output[0])
45−- subprocess.Popen(["xrandr", "--output", output.name, "--off"])
46−+ subprocess.Popen([LINUX_SYSTEM.get("xrandr"), "--output", output.name, "--off"])
47−
48−
49− def get_resolutions():
50−@@ -111,7 +112,7 @@ def change_resolution(resolution):
51− logger.warning("Resolution %s doesn't exist.", resolution)
52− else:
53− logger.info("Changing resolution to %s", resolution)
54−- subprocess.Popen(["xrandr", "-s", resolution])
55−+ subprocess.Popen([LINUX_SYSTEM.get("xrandr"), "-s", resolution])
56− else:
57− for display in resolution:
58− logger.debug("Switching to %s on %s", display.mode, display.name)
59−@@ -128,7 +129,7 @@ def change_resolution(resolution):
60− logger.info("Switching resolution of %s to %s", display.name, display.mode)
61− subprocess.Popen(
62− [
63−- "xrandr",
64−+ LINUX_SYSTEM.get("xrandr"),
65− "--output",
66− display.name,
67− "--mode",