Merge pull request #148095 from rvl/update-ddccontrol
ddccontrol: 0.5.2 -> 0.6.0
This commit is contained in:
commit
7240c085d0
@ -20,6 +20,9 @@ in
|
||||
###### implementation
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
# Load the i2c-dev module
|
||||
boot.kernelModules = [ "i2c_dev" ];
|
||||
|
||||
# Give users access to the "gddccontrol" tool
|
||||
environment.systemPackages = [
|
||||
pkgs.ddccontrol
|
||||
|
@ -12,13 +12,13 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "ddccontrol";
|
||||
version = "0.5.2";
|
||||
version = "0.6.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ddccontrol";
|
||||
repo = "ddccontrol";
|
||||
rev = "0.5.2";
|
||||
sha256 = "sha256-kul0sjbwbCwadvrccG3KwL/fKWACFUg74QGvgfWE4FQ=";
|
||||
rev = version;
|
||||
sha256 = "00pmnzvd4l3w6chzw41mrf1pd7lrcwi1n7320bnq20rn8hsnbnxk";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
@ -39,10 +39,17 @@ stdenv.mkDerivation rec {
|
||||
];
|
||||
|
||||
prePatch = ''
|
||||
oldPath="\$""{datadir}/ddccontrol-db"
|
||||
newPath="${ddccontrol-db}/share/ddccontrol-db"
|
||||
sed -i -e "s|$oldPath|$newPath|" configure.ac
|
||||
sed -i -e "s/chmod 4711/chmod 0711/" src/ddcpci/Makefile*
|
||||
substituteInPlace configure.ac \
|
||||
--replace \
|
||||
"\$""{datadir}/ddccontrol-db" \
|
||||
"${ddccontrol-db}/share/ddccontrol-db"
|
||||
|
||||
substituteInPlace src/ddcpci/Makefile.am \
|
||||
--replace "chmod 4711" "chmod 0711"
|
||||
'' + lib.optionalString (lib.versionAtLeast "0.6.0" version) ''
|
||||
# Upstream PR: https://github.com/ddccontrol/ddccontrol/pull/115
|
||||
substituteInPlace src/lib/Makefile.am \
|
||||
--replace "/etc/" "\$""{sysconfdir}/"
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
|
Loading…
Reference in New Issue
Block a user