aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--configure.ac32
-rw-r--r--include/HsUnix.h3
2 files changed, 34 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 0000000..08b05e8
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,32 @@
+AC_INIT([unix], [], [libraries@haskell.org], [unix])
+
+# Safety check: Ensure that we are in the correct source directory.
+AC_CONFIG_SRCDIR([include/HsUnix.h])
+
+AC_CONFIG_HEADERS([include/HsUnixConfig.h])
+
+AC_MSG_CHECKING([for _SC_GETGR_R_SIZE_MAX])
+AC_EGREP_CPP(we_have_that_sysconf_thing,
+[
+#include <unistd.h>
+#ifdef _SC_GETGR_R_SIZE_MAX
+we_have_that_sysconf_thing
+#endif
+],
+[AC_MSG_RESULT([yes])
+AC_DEFINE([HAVE_SC_GETGR_R_SIZE_MAX], [1], [Define to 1 if <unistd.h> defines _SC_GETGR_R_SIZE_MAX.])],
+[AC_MSG_RESULT([no])])
+
+AC_MSG_CHECKING([for _SC_GETPW_R_SIZE_MAX])
+AC_EGREP_CPP(we_have_that_sysconf_thing,
+[
+#include <unistd.h>
+#ifdef _SC_GETPW_R_SIZE_MAX
+we_have_that_sysconf_thing
+#endif
+],
+[AC_MSG_RESULT([yes])
+AC_DEFINE([HAVE_SC_GETPW_R_SIZE_MAX], [1], [Define to 1 if <unistd.h> defines _SC_GETPW_R_SIZE_MAX.])],
+[AC_MSG_RESULT([no])])
+
+AC_OUTPUT
diff --git a/include/HsUnix.h b/include/HsUnix.h
index e087fd4..fe857ae 100644
--- a/include/HsUnix.h
+++ b/include/HsUnix.h
@@ -1,5 +1,5 @@
/* -----------------------------------------------------------------------------
- * $Id: HsUnix.h,v 1.14 2004/08/13 13:29:11 simonmar Exp $
+ * $Id: HsUnix.h,v 1.15 2004/09/02 15:18:10 ross Exp $
*
* (c) The University of Glasgow 2002
*
@@ -11,6 +11,7 @@
#define HSUNIX_H
#include "ghcconfig.h"
+#include "HsUnixConfig.h"
#include <stdlib.h>
#include <stdio.h>