1
0
out-of-tree/default.nix

40 lines
844 B
Nix
Raw Permalink Normal View History

2023-05-16 11:47:17 +00:00
{ pkgs ? (
let
inherit (builtins) fetchTree fromJSON readFile;
inherit ((fromJSON (readFile ./flake.lock)).nodes) nixpkgs gomod2nix;
in
import (fetchTree nixpkgs.locked) {
overlays = [
(import "${fetchTree gomod2nix.locked}/overlay.nix")
];
}
)
, lib
2023-05-18 12:53:46 +00:00
, version
2023-05-16 11:47:17 +00:00
}:
pkgs.buildGoApplication rec {
pname = "out-of-tree";
2023-05-18 12:53:46 +00:00
inherit version;
2023-05-16 11:47:17 +00:00
nativeBuildInputs = [ pkgs.makeWrapper ];
src = ./.;
pwd = ./.;
doCheck = false;
postFixup = ''
wrapProgram $out/bin/out-of-tree \
2024-02-20 13:25:31 +00:00
--prefix PATH : "${lib.makeBinPath [ pkgs.qemu pkgs.podman pkgs.openssl ]}"
2023-05-16 11:47:17 +00:00
'';
meta = with lib; {
description = "kernel {module, exploit} development tool";
homepage = "https://out-of-tree.io";
maintainers = [ maintainers.dump_stack ];
license = licenses.agpl3Plus;
};
}