diff mbox series

[1/3] configure: Check for <sys/uio.h> header before external libraries

Message ID 20200307172222.14764-2-philmd@redhat.com (mailing list archive)
State New, archived
Headers show
Series buildsys: Fix building with SASL on Windows | expand

Commit Message

Philippe Mathieu-Daudé March 7, 2020, 5:22 p.m. UTC
In the next commit we will add a definition to the SASL CFLAGS,
depending whether the scatter/gather I/O include is present.
Move the  <sys/uio.h> header check before the external libraries
checks.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
 configure | 52 ++++++++++++++++++++++++++--------------------------
 1 file changed, 26 insertions(+), 26 deletions(-)
diff mbox series

Patch

diff --git a/configure b/configure
index cbf864bff1..0c2dd1eb08 100755
--- a/configure
+++ b/configure
@@ -2340,6 +2340,32 @@  if test "$vhost_net" = ""; then
   test "$vhost_kernel" = "yes" && vhost_net=yes
 fi
 
+##########################################
+# iovec probe
+cat > $TMPC <<EOF
+#include <sys/types.h>
+#include <sys/uio.h>
+#include <unistd.h>
+int main(void) { return sizeof(struct iovec); }
+EOF
+iovec=no
+if compile_prog "" "" ; then
+  iovec=yes
+fi
+
+##########################################
+# preadv probe
+cat > $TMPC <<EOF
+#include <sys/types.h>
+#include <sys/uio.h>
+#include <unistd.h>
+int main(void) { return preadv(0, 0, 0, 0); }
+EOF
+preadv=no
+if compile_prog "" "" ; then
+  preadv=yes
+fi
+
 ##########################################
 # MinGW / Mingw-w64 localtime_r/gmtime_r check
 
@@ -4145,32 +4171,6 @@  EOF
   fi
 fi
 
-##########################################
-# iovec probe
-cat > $TMPC <<EOF
-#include <sys/types.h>
-#include <sys/uio.h>
-#include <unistd.h>
-int main(void) { return sizeof(struct iovec); }
-EOF
-iovec=no
-if compile_prog "" "" ; then
-  iovec=yes
-fi
-
-##########################################
-# preadv probe
-cat > $TMPC <<EOF
-#include <sys/types.h>
-#include <sys/uio.h>
-#include <unistd.h>
-int main(void) { return preadv(0, 0, 0, 0); }
-EOF
-preadv=no
-if compile_prog "" "" ; then
-  preadv=yes
-fi
-
 ##########################################
 # fdt probe
 # fdt support is mandatory for at least some target architectures,