Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gamemode: init at 1.4 #67779

Closed
wants to merge 1 commit into from
Closed

gamemode: init at 1.4 #67779

wants to merge 1 commit into from

Conversation

leo60228
Copy link
Member

Motivation for this change

GameMode is a pretty popular package. It requires a daemon as well, which I have not written a NixOS module for due to a lack of experience. If necessary, I can add it to this or a separate PR.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
    • Had issues with it while reinstalling NixOS, so disabled it
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

pkgs/games/gamemode/default.nix Outdated Show resolved Hide resolved
pkgs/games/gamemode/default.nix Outdated Show resolved Hide resolved
pkgs/games/gamemode/default.nix Outdated Show resolved Hide resolved
@frio
Copy link

frio commented Sep 6, 2019

I've got a similar package I've been working on. There's a few more patches I've added in prep for a NixOS module to add the daemon; in particular, setting the default config file location (/usr/share/gamemode won't exist in a running NixOS), fixing the dlopen call, and fixing the polkit calls. I don't have the LD_LIBRARY changes you do, so maybe the second two changes I've made are redundant. If you're OK with this sitting for a day (work's busy atm), I can push you the config file patch?

Also -- some games that can be run with this are still 32-bit, so I tried to get a multiarch build going but eventually had to give up. Have you looked into that at all? (Oh, and -- once done, I might see if we can add this as a dependency for Lutris so that it can toggle gamemode on).

This is exciting, thanks for doing this :).

@frio
Copy link

frio commented Sep 8, 2019

For reference: https://gist.github.com/frio/03a2731903bf40ae0c11b2c99a24dedf. I've got no further input, I'm really happy to see this and would be happy to put together a module when merged :).

Copy link
Contributor

@drewrisinger drewrisinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few small suggestions.

src = fetchFromGitHub {
owner = "FeralInteractive";
repo = "gamemode";
rev = "7ced21f4b30cc4ceb67928889bc57af8784f1009";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
rev = "7ced21f4b30cc4ceb67928889bc57af8784f1009";
rev = version;


meta = with stdenv.lib; {
description = "Optimise Linux system performance on demand";
homepage = https://github.com/FeralInteractive/GameMode/;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quote homepage per RFC45

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or simply use src.meta.homepage ;)

@Kloenk
Copy link
Member

Kloenk commented Sep 21, 2020

Fixes: #84682

Copy link
Member

@ryantm ryantm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please apply drewrisinger's changes

@@ -0,0 +1,30 @@
{ stdenv, meson, ninja, fetchFromGitHub, systemd, pkgconfig, dbus }:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
{ stdenv, meson, ninja, fetchFromGitHub, systemd, pkgconfig, dbus }:
{ stdenv, meson, ninja, fetchFromGitHub, systemd, pkg-config, dbus }:

pname = "gamemode";
version = "1.4";

nativeBuildInputs = [ meson ninja pkgconfig ];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
nativeBuildInputs = [ meson ninja pkgconfig ];
nativeBuildInputs = [ meson ninja pkg-config ];

@kira-bruneau
Copy link
Contributor

kira-bruneau commented May 15, 2021

I would love to see this merged! @leo60228 are you still willing to maintain this? The suggestions in this PR haven't been resolved and this has been stale for a while now.

I'd be willing to start a new PR based off of this using v1.6.1 + a NixOS module.

@leo60228
Copy link
Member Author

I've mostly lost interest in this package. It'd be great if you were willing to make a new PR, though!

@leo60228 leo60228 closed this May 15, 2021
@kira-bruneau kira-bruneau mentioned this pull request May 18, 2021
10 tasks
@kira-bruneau
Copy link
Contributor

I've created a new PR for GameMode here: #123433 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

10 participants