From 5d2cc394194b2899754e537c3e2e9b78a37273a0 Mon Sep 17 00:00:00 2001 From: Luke Granger-Brown Date: Sat, 25 Sep 2021 12:55:06 +0000 Subject: [PATCH] nix/pkgs: add eapol-test --- nix/pkgs/default.nix | 1 + nix/pkgs/eapol-test.nix | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 nix/pkgs/eapol-test.nix diff --git a/nix/pkgs/default.nix b/nix/pkgs/default.nix index d412792c91..701761c299 100644 --- a/nix/pkgs/default.nix +++ b/nix/pkgs/default.nix @@ -33,5 +33,6 @@ })); netbox = pkgs.python3Packages.callPackage ./netbox {}; prometheus-bird-exporter-lfty = pkgs.callPackage ./prometheus-bird-exporter-lfty.nix {}; + eapol-test = pkgs.callPackage ./eapol-test.nix {}; } // (import ./heptapod-runner.nix args) // (import ./lightspeed args) diff --git a/nix/pkgs/eapol-test.nix b/nix/pkgs/eapol-test.nix new file mode 100644 index 0000000000..2c73964183 --- /dev/null +++ b/nix/pkgs/eapol-test.nix @@ -0,0 +1,21 @@ +{ wpa_supplicant }: + +wpa_supplicant.overrideAttrs (old: { + pname = "${old.pname}-eapol_test"; + + enableParallelBuilding = true; + buildFlags = [ "eapol_test" "preauth_test" ]; + + preInstall = ":"; + postInstall = ":"; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin + install -Dm755 eapol_test $out/bin/eapol_test + install -Dm755 preauth_test $out/bin/preauth_test + + runHook postInstall + ''; +})