From 6bc52c386fe9b6aebb8b18533e6009021e955500 Mon Sep 17 00:00:00 2001 From: Soham S Gumaste Date: Sat, 8 Jul 2023 12:54:16 -0500 Subject: [PATCH] oddjob: init at 0.34.7 --- pkgs/os-specific/linux/oddjob/default.nix | 60 +++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 62 insertions(+) create mode 100644 pkgs/os-specific/linux/oddjob/default.nix diff --git a/pkgs/os-specific/linux/oddjob/default.nix b/pkgs/os-specific/linux/oddjob/default.nix new file mode 100644 index 000000000000..bcbea9086488 --- /dev/null +++ b/pkgs/os-specific/linux/oddjob/default.nix @@ -0,0 +1,60 @@ +{ lib +, fetchurl +, stdenv +, autoreconfHook +, dbus +, libxml2 +, pam +, pkg-config +, systemd +}: + +stdenv.mkDerivation rec { + pname = "oddjob"; + version = "0.34.7"; + + src = fetchurl { + url = "https://pagure.io/oddjob/archive/${pname}-${version}/oddjob-${pname}-${version}.tar.gz"; + hash = "sha256-SUOsMH55HtEsk5rX0CXK0apDObTj738FGOaL5xZRnIM="; + }; + + nativeBuildInputs = [ + autoreconfHook + pkg-config + ]; + + buildInputs =[ + libxml2 + dbus + pam + 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" + ]; + + postConfigure = '' + substituteInPlace src/oddjobd.c \ + --replace "globals.selinux_enabled" "FALSE" + ''; + + meta = with lib; { + description = "Odd Job Daemon"; + homepage = "https://pagure.io/oddjob"; + changelog = "https://pagure.io/oddjob/blob/oddjob-${version}/f/ChangeLog"; + license = licenses.bsd0; + platforms = platforms.linux; + maintainers = with maintainers; [ SohamG ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 9646ec6e0311..03e816cbd1e5 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9878,6 +9878,8 @@ with pkgs; notesnook = callPackage ../applications/misc/notesnook { }; + oddjob = callPackage ../os-specific/linux/oddjob { }; + openipmi = callPackage ../tools/system/openipmi { }; ox = callPackage ../applications/editors/ox { };