]> granicus.if.org Git - strace/commitdiff
add more configure tests for system headers
authorWichert Akkerman <wichert@deephackmode.org>
Tue, 10 Apr 2001 10:32:26 +0000 (10:32 +0000)
committerWichert Akkerman <wichert@deephackmode.org>
Tue, 10 Apr 2001 10:32:26 +0000 (10:32 +0000)
ChangeLog
configure.in
stream.c

index 98a7185ae09c472d572b7179cbf81fab42740f64..bb02532fcf0e64aa7361075c714051292219deee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,8 @@
     + util.c: add code to print PC for MIPS
     + linux/mips/syscallent.h: updated
     + system.c: formating fixes for sys_sysmips
+    + configure.in: test for yet more headers
+    + stream.c: use configure-headertests instead of relying on OS hints
 
 2001-04-07  Wichert Akkerman <wakkerma@debian.org>
 
index f4425a85c2668491bfda7736e8973bac8888fcbf..d5cfcf069e5743df63ad6bbed7b4e0f7f05acca2 100644 (file)
@@ -163,7 +163,7 @@ if test x$OPSYS != xLINUX; then
 AC_CHECK_LIB(nsl, main)
 fi
 AC_CHECK_FUNCS(sigaction strerror strsignal pread sys_siglist _sys_siglist getdents mctl putpmsg prctl sendmsg inet_ntop if_indextoname)
-AC_CHECK_HEADERS(sys/reg.h sys/filio.h sys/acl.h sys/asynch.h sys/door.h sys/stream.h sys/tiuser.h sys/sysconfig.h asm/sigcontext.h ioctls.h sys/ioctl.h sys/ptrace.h termio.h linux/ptrace.h asm/reg.h linux/icmp.h linux/in6.h sys/uio.h sys/aio.h linux/netlink.h linux/if_packet.h sys/poll.h sys/vfs.h netinet/tcp.h netinet/udp.h asm/sysmips.h linux/utsname.h)
+AC_CHECK_HEADERS(sys/reg.h sys/filio.h sys/acl.h sys/asynch.h sys/door.h stropts.h sys/conf.h sys/stream.h sys/tihdr.h sys/tiuser.h sys/sysconfig.h asm/sigcontext.h ioctls.h sys/ioctl.h sys/ptrace.h termio.h linux/ptrace.h asm/reg.h linux/icmp.h linux/in6.h sys/uio.h sys/aio.h linux/netlink.h linux/if_packet.h poll.h sys/poll.h sys/vfs.h netinet/tcp.h netinet/udp.h asm/sysmips.h linux/utsname.h)
 AC_DECL_SYS_ERRLIST
 AC_DECL_SYS_SIGLIST
 AC_DECL__SYS_SIGLIST
index 1c2667270bfb3b2483e1e980ad5b2372def12f57..872ba5947c90c3a55420c15782eac28fbca0ef03 100644 (file)
--- a/stream.c
+++ b/stream.c
 
 #include "defs.h"
 
-#if defined(HAVE_SYS_STREAM_H) || defined(linux) || defined(FREEBSD)
-
-#if defined(linux)
+#ifdef HAVE_POLL_H
+#include <poll.h>
+#endif
 #ifdef HAVE_SYS_POLL_H
 #include <sys/poll.h>
 #endif
+#ifdef HAVE_STROPTS_H
+#include <stropts.h>
+#endif
+#ifdef HAVE_SYS_CONF_H
+#include <sys/conf.h>
+#endif
+#ifdef HAVE_SYS_STREAM_H
+#include <sys/stream.h>
+#endif
+#ifdef HAVE_SYS_TIHDR_H
+#include <sys/tihdr.h>
+#endif
 
+#if defined(HAVE_SYS_STREAM_H) || defined(linux) || defined(FREEBSD)
+
+#ifndef HAVE_STROPTS_H
 #define RS_HIPRI 1
 struct strbuf {
         int     maxlen;                 /* no. of bytes in buffer */
@@ -45,20 +60,7 @@ struct strbuf {
 };
 #define MORECTL 1
 #define MOREDATA 2
-
-#else /* linux */
-
-#ifndef FREEBSD
-#include <stropts.h>
-#include <poll.h>
-#include <sys/conf.h>
-#include <sys/stream.h>
-#include <sys/tihdr.h>
-#else /* FREEBSD */
-#include <poll.h>
-#endif /* FREEBSD */
-
-#endif /* linux */
+#endif /* !HAVE_STROPTS_H */
 
 #ifdef HAVE_SYS_TIUSER_H
 #include <sys/tiuser.h>