Skip to content

Commit

Permalink
modprobed-db: init at 2.46
Browse files Browse the repository at this point in the history
  • Loading branch information
NotAShelf committed Jan 14, 2024
1 parent 777770d commit 08c9ea8
Showing 1 changed file with 50 additions and 0 deletions.
50 changes: 50 additions & 0 deletions pkgs/by-name/mo/modprobed-db/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{ lib
, stdenv
, fetchFromGitHub
, pkg-config
, libevdev
, kmod
, bash
, installShellFiles
}:
let
pname = "modprobed-db";
version = "2.46";
in
stdenv.mkDerivation {
inherit pname version;

src = fetchFromGitHub {
owner = "graysky2";
repo = "modprobed-db";
rev = "v${version}";
hash = "sha256-GQME5CAZsGVHSPowKQMyUR7OjHeFZi/5YcWFUT9L/AQ=";
};

strictDeps = true;
nativeBuildInputs = [ pkg-config installShellFiles ];
buildInputs = [ kmod libevdev bash ];

installFlags = [
"PREFIX=$(out)"
"INITDIR_SYSTEMD=$(out)/lib/systemd/user"
];

postPatch = ''
substituteInPlace ./common/modprobed-db.in \
--replace "/usr/share" "$out/share"
'';

postInstall = ''
installShellCompletion --zsh common/zsh-completion
'';

meta = {
homepage = "https://github.com/graysky2/modprobed-db";
description = "Useful utility for users wishing to build a minimal kernel via a make localmodconfig";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ NotAShelf ];
mainProgram = "modprobed-db";
platforms = lib.platforms.linux;
};
}

0 comments on commit 08c9ea8

Please sign in to comment.