aboutsummaryrefslogtreecommitdiff
path: root/libmudflap/mf-hooks2.c
diff options
context:
space:
mode:
authorPer Bothner <per@bothner.com>2004-06-04 10:20:22 -0700
committerPer Bothner <bothner@gcc.gnu.org>2004-06-04 10:20:22 -0700
commitb9d71ce3e4860dd7ae12039eaa05c9731b12a095 (patch)
tree5dcf7fe1d68429aacfe1225763a6f492a238d0e5 /libmudflap/mf-hooks2.c
parent14bbffa1d211ad505bc165f762027596b87511f1 (diff)
downloadgcc-b9d71ce3e4860dd7ae12039eaa05c9731b12a095.zip
gcc-b9d71ce3e4860dd7ae12039eaa05c9731b12a095.tar.gz
gcc-b9d71ce3e4860dd7ae12039eaa05c9731b12a095.tar.bz2
configure.in (LIBMUDFLAPTH): Fix thinko.
* configure.in (LIBMUDFLAPTH): Fix thinko. * configure.in: Check for more headers. * mf-hooks2.c: Conditionalize on HAVE_SYS_SOCKET_H etc. * mf-runtime.c: In two places conditionalize on SIUSR1 rather than HAVE_SIGNAL as mingw has signal.h but not SIUSR1. From-SVN: r82627
Diffstat (limited to 'libmudflap/mf-hooks2.c')
-rw-r--r--libmudflap/mf-hooks2.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/libmudflap/mf-hooks2.c b/libmudflap/mf-hooks2.c
index b086772..601dc24 100644
--- a/libmudflap/mf-hooks2.c
+++ b/libmudflap/mf-hooks2.c
@@ -1206,6 +1206,8 @@ WRAPPER2(struct dirent *, readdir, DIR *dir)
}
#endif
+#ifdef HAVE_SYS_SOCKET_H
+
#ifdef WRAP_recv
#include <sys/socket.h>
WRAPPER2(int, recv, int s, void *buf, size_t len, int flags)
@@ -1327,6 +1329,8 @@ WRAPPER2(int, connect, int sockfd, const struct sockaddr *addr,
}
#endif
+#endif /* HAVE_SYS_SOCKET_H */
+
#ifdef WRAP_gethostname
WRAPPER2(int, gethostname, char *name, size_t len)
{
@@ -1345,6 +1349,8 @@ WRAPPER2(int, sethostname, const char *name, size_t len)
}
#endif
+#ifdef HAVE_NETDB_H
+
#ifdef WRAP_gethostbyname
#include <netdb.h>
WRAPPER2(struct hostent *, gethostbyname, const char *name)
@@ -1425,6 +1431,10 @@ WRAPPER2(struct hostent *, gethostbyname, const char *name)
}
#endif
+#endif /* HAVE_NETDB_H */
+
+#ifdef SYS_WAIT_H
+
#ifdef WRAP_wait
#include <sys/wait.h>
WRAPPER2(pid_t, wait, int *status)
@@ -1449,6 +1459,8 @@ WRAPPER2(pid_t, waitpid, pid_t pid, int *status, int options)
}
#endif
+#endif /* HAVE_SYS_WAIT_H */
+
#ifdef WRAP_popen
WRAPPER2(FILE *, popen, const char *command, const char *mode)
{
@@ -1651,6 +1663,8 @@ WRAPPER2(void *, dlsym, void *handle, char *symbol)
}
#endif
+#if defined(HAVE_SYS_IPC_H) && defined(HAVE_SYS_SEM_H)
+
#ifdef WRAP_semop
#include <sys/ipc.h>
#include <sys/sem.h>
@@ -1765,3 +1779,5 @@ WRAPPER2(int, shmdt, const void *shmaddr)
}
#endif
+#endif /* defined(HAVE_SYS_IPC_H) && defined(HAVE_SYS_SEM_H) */
+