summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2013-10-22 09:21:54 (GMT)
committerChristian Heimes <christian@cheimes.de>2013-10-22 09:21:54 (GMT)
commitb7bd5df809aabaf857eb51b139d5e519d8b3c364 (patch)
treed4fb23b4eca52906c84473365a6a0e44c792a7e4 /configure
parent6fc79bf813de21015208d989e38cdc95bda03292 (diff)
downloadcpython-b7bd5df809aabaf857eb51b139d5e519d8b3c364.zip
cpython-b7bd5df809aabaf857eb51b139d5e519d8b3c364.tar.gz
cpython-b7bd5df809aabaf857eb51b139d5e519d8b3c364.tar.bz2
Issue #16595: Add prlimit() to resource module
prlimit() is a Linux specific command that combines setrlimit, getrlimit and can set the limit of other processes.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure29
1 files changed, 29 insertions, 0 deletions
diff --git a/configure b/configure
index 83d0ee2..fb1404f 100755
--- a/configure
+++ b/configure
@@ -10601,6 +10601,35 @@ $as_echo "no" >&6; }
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for prlimit" >&5
+$as_echo_n "checking for prlimit... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+#include <sys/time.h>
+#include <sys/resource.h>
+
+int
+main ()
+{
+void *x=prlimit
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+$as_echo "#define HAVE_PRLIMIT 1" >>confdefs.h
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
# On some systems (eg. FreeBSD 5), we would find a definition of the
# functions ctermid_r, setgroups in the library, but no prototype
# (e.g. because we use _XOPEN_SOURCE). See whether we can take their