1 |
commit: 8aecc9b9d855f27f70c12e103e62aa228a423783 |
2 |
Author: Kai Krakow <kai <AT> kaishome <DOT> de> |
3 |
AuthorDate: Sun Sep 20 11:10:11 2020 +0000 |
4 |
Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Sep 28 11:32:58 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8aecc9b9 |
7 |
|
8 |
games-util/gamemode: Update 9999 ebuild |
9 |
|
10 |
This updates the 9999 version to reflect the changes from upstream. |
11 |
|
12 |
This also hacks around a header problem in multilib and removes the |
13 |
hard dependency on systemd. |
14 |
|
15 |
Closes: https://bugs.gentoo.org/722884 |
16 |
Package-Manager: Portage-3.0.4, Repoman-3.0.1 |
17 |
Signed-off-by: Kai Krakow <kai <AT> kaishome.de> |
18 |
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org> |
19 |
|
20 |
games-util/gamemode/gamemode-9999.ebuild | 61 +++++++++++++++++++++++--------- |
21 |
1 file changed, 44 insertions(+), 17 deletions(-) |
22 |
|
23 |
diff --git a/games-util/gamemode/gamemode-9999.ebuild b/games-util/gamemode/gamemode-9999.ebuild |
24 |
index 45b778ba90e..0af83005b8c 100644 |
25 |
--- a/games-util/gamemode/gamemode-9999.ebuild |
26 |
+++ b/games-util/gamemode/gamemode-9999.ebuild |
27 |
@@ -1,11 +1,11 @@ |
28 |
-# Copyright 1999-2018 Gentoo Foundation |
29 |
+# Copyright 2020 Gentoo Authors |
30 |
# Distributed under the terms of the GNU General Public License v2 |
31 |
|
32 |
-EAPI=6 |
33 |
+EAPI=7 |
34 |
|
35 |
MULTILIB_COMPAT=( abi_x86_{32,64} ) |
36 |
|
37 |
-inherit meson multilib-minimal ninja-utils user |
38 |
+inherit meson multilib-minimal ninja-utils systemd |
39 |
|
40 |
DESCRIPTION="Optimise Linux system performance on demand" |
41 |
HOMEPAGE="https://github.com/FeralInteractive/gamemode" |
42 |
@@ -22,14 +22,26 @@ fi |
43 |
|
44 |
LICENSE="BSD" |
45 |
SLOT="0" |
46 |
-IUSE="" |
47 |
+IUSE="systemd elogind" |
48 |
+ |
49 |
+REQUIRED_USE="^^ ( systemd elogind )" |
50 |
|
51 |
RDEPEND=" |
52 |
- >=sys-apps/systemd-236[${MULTILIB_USEDEP}] |
53 |
+ acct-group/gamemode |
54 |
+ dev-libs/inih |
55 |
+ sys-apps/dbus[${MULTILIB_USEDEP},systemd(+)=,elogind(-)=] |
56 |
sys-auth/polkit |
57 |
+ sys-libs/libcap |
58 |
" |
59 |
DEPEND="${RDEPEND}" |
60 |
|
61 |
+DOCS=( |
62 |
+ CHANGELOG.md |
63 |
+ LICENSE.txt |
64 |
+ README.md |
65 |
+ example/gamemode.ini |
66 |
+) |
67 |
+ |
68 |
pkg_pretend() { |
69 |
elog |
70 |
elog "GameMode needs a kernel capable of SCHED_ISO to use its soft realtime" |
71 |
@@ -64,14 +76,18 @@ pkg_pretend() { |
72 |
} |
73 |
|
74 |
multilib_src_configure() { |
75 |
- local myconf=() |
76 |
+ local emesonargs=( |
77 |
+ -Dwith-sd-bus-provider=$(usex systemd "systemd" "elogind") |
78 |
+ -Dwith-systemd-user-unit-dir="$(systemd_get_userunitdir)" |
79 |
+ ) |
80 |
if ! multilib_is_native_abi; then |
81 |
- myconf+=( |
82 |
+ emesonargs+=( |
83 |
-Dwith-examples=false |
84 |
- -Dwith-daemon=false |
85 |
+ -Dwith-sd-bus-provider=no-daemon |
86 |
) |
87 |
fi |
88 |
- meson_src_configure "${myconf[@]}" |
89 |
+ |
90 |
+ meson_src_configure |
91 |
} |
92 |
|
93 |
multilib_src_compile() { |
94 |
@@ -89,17 +105,28 @@ multilib_src_install() { |
95 |
} |
96 |
|
97 |
pkg_postinst() { |
98 |
- enewgroup gamemode |
99 |
- |
100 |
elog |
101 |
- elog "GameMode can renice your games. You need to be in the gamemode group for this to work." |
102 |
+ elog "GameMode has optional support for adjusting nice and ioprio of games" |
103 |
+ elog "running with it. You may need to adjust your PAM limits to make use" |
104 |
+ elog "of this. You need to be in the gamemode group for this to work." |
105 |
+ elog |
106 |
elog "Run the following command as root to add your user:" |
107 |
elog "# gpasswd -a USER gamemode # with USER = your user name" |
108 |
elog |
109 |
- |
110 |
- elog "Enable and start the daemon in your systemd user instance, then add" |
111 |
- elog "LD_PRELOAD=\$LD_PRELOAD:/usr/\$LIB/libgamemodeauto.so %command%" |
112 |
- elog "to the start options of any steam game to enable the performance" |
113 |
- elog "governor as you start the game." |
114 |
+ elog "You can run the following command to test your settings:" |
115 |
+ elog |
116 |
+ elog "# gamemoded -t" |
117 |
+ elog |
118 |
+ elog "GameMode supports GPU optimizations. It defaults to OFF. Any" |
119 |
+ elog "damage resulting from usage of this is your own responsibility." |
120 |
+ elog |
121 |
+ elog "systemd user sessions will automatically run the daemon on demand," |
122 |
+ elog "it does not need to be enabled explicitly. Games not supporting" |
123 |
+ elog "GameMode natively can still make use of it, just add" |
124 |
+ elog |
125 |
+ elog "gamemoderun %command%" |
126 |
+ elog |
127 |
+ elog "to the start options of any steam game to enable optimizations" |
128 |
+ elog "automatically as you start the game." |
129 |
elog |
130 |
} |