mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-27 05:43:50 +03:00
powertop: call "xset" from $PATH
Patch the source code to find "xset" in $PATH rather than expecting the hard-coded path "/usr/bin/xset" to work. I've decided *not* to hard-code a proper path like "${xset}/bin/xset", because that reference greatly increases the size of the powertop closure. Since "xset" is required only for --calibrate (and that even seems to work fine without it), it felt like an optional dependency is more appropriate in this case. Thanks to @heydojo locating the source code file that needs patching. Fixes https://github.com/NixOS/nixpkgs/issues/12662.
This commit is contained in:
parent
268d4699ec
commit
b7badc6be0
@ -12,6 +12,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace src/main.cpp --replace "/sbin/modprobe" "modprobe"
|
||||
substituteInPlace src/calibrate/calibrate.cpp --replace "/usr/bin/xset" "xset"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
Loading…
Reference in New Issue
Block a user