Unverified Commit a8304edc authored by Rick van Schijndel's avatar Rick van Schijndel Committed by GitHub
Browse files

Merge pull request #277744 from NickCao/keepalived

keepalived: disable net-snmp support when cross compiling
parents 9323295d b04954bf
Loading
Loading
Loading
Loading
+18 −6
Original line number Diff line number Diff line
{ lib, stdenv, fetchFromGitHub, nixosTests
, file, libmnl, libnftnl, libnl
, net-snmp, openssl, pkg-config
, autoreconfHook }:
{ lib
, stdenv
, fetchFromGitHub
, nixosTests
, file
, libmnl
, libnftnl
, libnl
, net-snmp
, openssl
, pkg-config
, autoreconfHook
, withNetSnmp ? stdenv.buildPlatform.canExecute stdenv.hostPlatform
}:

stdenv.mkDerivation rec {
  pname = "keepalived";
@@ -19,8 +29,9 @@ stdenv.mkDerivation rec {
    libmnl
    libnftnl
    libnl
    net-snmp
    openssl
  ] ++ lib.optionals withNetSnmp [
    net-snmp
  ];

  enableParallelBuilding = true;
@@ -31,6 +42,7 @@ stdenv.mkDerivation rec {

  configureFlags = [
    "--enable-sha1"
  ] ++ lib.optionals withNetSnmp [
    "--enable-snmp"
  ];