keepalived: Add libnl support

This commit is contained in:
William A. Kennington III 2015-06-27 19:59:44 -07:00
parent e44d325c27
commit 3ea1c5bc0c

View File

@ -1,4 +1,4 @@
{ stdenv, fetchurl, openssl, net_snmp }: { stdenv, fetchurl, openssl, net_snmp, libnl }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "keepalived-1.2.17"; name = "keepalived-1.2.17";
@ -8,12 +8,16 @@ stdenv.mkDerivation rec {
sha256 = "1w7px8phx3pyb3b56m3nz1a9ncx26q34fgy8j4n2dpi284jmqm6z"; sha256 = "1w7px8phx3pyb3b56m3nz1a9ncx26q34fgy8j4n2dpi284jmqm6z";
}; };
buildInputs = [ openssl net_snmp ]; buildInputs = [ openssl net_snmp libnl ];
postPatch = '' postPatch = ''
sed -i 's,$(DESTDIR)/usr/share,$out/share,g' Makefile.in sed -i 's,$(DESTDIR)/usr/share,$out/share,g' Makefile.in
''; '';
# It doesn't know about the include/libnl<n> directory
NIX_CFLAGS_COMPILE="-I${libnl}/include/libnl3";
NIX_LDFLAGS="-lnl-3 -lnl-genl-3";
configureFlags = [ configureFlags = [
"--sysconfdir=/etc" "--sysconfdir=/etc"
"--localstatedir=/var" "--localstatedir=/var"