diff options
author | Anthony Roussel <anthony@roussel.dev> | 2024-04-07 00:30:21 +0200 |
---|---|---|
committer | Anthony Roussel <anthony@roussel.dev> | 2024-04-07 20:29:31 +0200 |
commit | f42230b64c9bb0badf684199841340a19c708882 (patch) | |
tree | 2278c6fed8981f278ca7d0ee37de160b7be3b4f0 | |
parent | e3cd9db7924a6506a3fe6cba8df5ed7f8eb33980 (diff) |
oddjob: move oddjobd.service SystemD service to lib/systemd/system
-rw-r--r-- | pkgs/os-specific/linux/oddjob/default.nix | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/pkgs/os-specific/linux/oddjob/default.nix b/pkgs/os-specific/linux/oddjob/default.nix index ac2f3ce4e3282..ce1dd2a265677 100644 --- a/pkgs/os-specific/linux/oddjob/default.nix +++ b/pkgs/os-specific/linux/oddjob/default.nix @@ -1,4 +1,5 @@ { lib +, fetchpatch , fetchurl , stdenv , autoreconfHook @@ -19,6 +20,14 @@ stdenv.mkDerivation rec { hash = "sha256-SUOsMH55HtEsk5rX0CXK0apDObTj738FGOaL5xZRnIM="; }; + patches = [ + # Define SystemD service location using `with-systemdsystemunitdir` configure flag + (fetchpatch { + url = "https://pagure.io/oddjob/c/f63287a35107385dcb6e04a4c742077c9d1eab86.patch"; + hash = "sha256-2mmw4pJhrIk4/47FM8zKH0dTQJWnntHPNmq8VAUWqJI="; + }) + ]; + nativeBuildInputs = [ autoreconfHook pkg-config @@ -31,18 +40,12 @@ stdenv.mkDerivation rec { systemd ]; - postPatch = '' - substituteInPlace configure.ac \ - --replace 'SYSTEMDSYSTEMUNITDIR=`pkg-config --variable=systemdsystemunitdir systemd 2> /dev/null`' "SYSTEMDSYSTEMUNITDIR=${placeholder "out"}" \ - --replace 'SYSTEMDSYSTEMUNITDIR=`pkg-config --variable=systemdsystemunitdir systemd`' "SYSTEMDSYSTEMUNITDIR=${placeholder "out"}" - ''; - configureFlags = [ "--prefix=${placeholder "out"}" "--sysconfdir=${placeholder "out"}/etc" "--with-selinux-acls=no" "--with-selinux-labels=no" - "--disable-systemd" + "--with-systemdsystemunitdir=${placeholder "out"}/lib/systemd/system" ]; postConfigure = '' |