libnscd: fix build with glibc 2.26

Tracking issue: #31696
This commit is contained in:
Orivej Desh 2017-11-15 22:57:03 +00:00
parent 6ab109a673
commit ea011d65a8
2 changed files with 18 additions and 2 deletions

View file

@ -1,13 +1,17 @@
{stdenv, fetchurl}:
stdenv.mkDerivation {
name = "libnscd-2.0.2";
src = fetchurl {
url = http://ftp.suse.com/pub/people/kukuk/libnscd/libnscd-2.0.2.tar.bz2;
sha256 = "0nxhwy42x44jlpdb5xq1prbvfjmds4hplmwv3687z0c4r9rn506l";
};
patches = [ ./libnscd-2.0.2-glibc-2.26.patch ];
NIX_CFLAGS_COMPILE = [ "-Wno-cast-qual" ];
meta = {
platforms = stdenv.lib.platforms.linux;
};

View file

@ -0,0 +1,12 @@
diff --git a/src/libnscd.c b/src/libnscd.c
index 5e1d3fd..73cb122 100644
--- a/src/libnscd.c
+++ b/src/libnscd.c
@@ -27,6 +27,7 @@
#include <unistd.h>
#include <sys/socket.h>
#include <sys/un.h>
+#include <sys/uio.h>
#include "libnscd.h"