From 8706664ff69444ed1d576250901a4d45cb17c690 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Tue, 5 Sep 2017 21:59:43 +0200 Subject: [PATCH] afl: use clangStdenv Fixes #28712 --- pkgs/tools/security/afl/default.nix | 6 ++++-- pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/security/afl/default.nix b/pkgs/tools/security/afl/default.nix index 4c3dfe4d07cc..5b96e513fd49 100644 --- a/pkgs/tools/security/afl/default.nix +++ b/pkgs/tools/security/afl/default.nix @@ -1,5 +1,6 @@ { stdenv, fetchurl, bash, callPackage, makeWrapper -, clang, llvm, which, libcgroup }: +, clang, llvm, which, libcgroup +}: let afl-qemu = callPackage ./qemu.nix {}; @@ -7,6 +8,7 @@ let else if stdenv.system == "i686-linux" then "qemu-i386" else throw "afl: no support for ${stdenv.system}!"; in + stdenv.mkDerivation rec { name = "afl-${version}"; version = "2.48b"; @@ -23,7 +25,7 @@ stdenv.mkDerivation rec { buildPhase = '' make PREFIX=$out cd llvm_mode - make PREFIX=$out CC=${clang}/bin/clang CXX=${clang}/bin/clang++ + make PREFIX=$out cd .. ''; installPhase = '' diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1aa06ccfa116..848850b2f4d0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -396,7 +396,9 @@ with pkgs; afio = callPackage ../tools/archivers/afio { }; - afl = callPackage ../tools/security/afl { }; + afl = callPackage ../tools/security/afl { + stdenv = clangStdenv; + }; afpfs-ng = callPackage ../tools/filesystems/afpfs-ng/default.nix { };