git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #4707 from wmertens/libpcap-darwin

libpcap: Force detection on Darwin

commitfc4cf2496539b5c14910b3e767a044c975620be1 authorPeter Simons <simons@cryp.to> dateThu 30 Oct 2014, 19:27 (12 years ago) parenta156a6b6d4b7d3
1 file changed+6−1
pkgs/development/libraries/libpcap/default.nix+6−1
pkgs/development/libraries/libpcap/default.nix+6−1
@@ -10,7 +10,12 @@ stdenv.mkDerivation rec {
1010
1111 nativeBuildInputs = [ flex bison ];
1212
13− configureFlags = stdenv.lib.optionals stdenv.isLinux "--with-pcap=linux";
13+ # We need to force the autodetection because detection doesn't
14+ # work in pure build enviroments.
15+ configureFlags =
16+ if stdenv.isLinux then [ "--with-pcap=linux" ]
17+ else if stdenv.isDarwin then [ "--with-pcap=bpf" ]
18+ else [];
1419
1520 preInstall = ''mkdir -p $out/bin'';
1621