summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2018-09-12 15:52:40 -0700
committerGitHub <noreply@github.com>2018-09-12 15:52:40 -0700
commit40caa05fa4d1810a1a6bfc34e0ec930c351089b7 (patch)
tree7d64642db943b1c395ffac9097d52727498a8ce4 /configure.ac
parent2087023fdec2c89070bd14f384a3c308c548a94a (diff)
downloadcpython-git-40caa05fa4d1810a1a6bfc34e0ec930c351089b7.tar.gz
closes bpo-34652: Always disable lchmod on Linux. (GH-9234)
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 7 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index a985ec2b00..cf7328c403 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3454,6 +3454,13 @@ AC_CHECK_FUNCS(alarm accept4 setitimer getitimer bind_textdomain_codeset chown \
truncate uname unlinkat unsetenv utimensat utimes waitid waitpid wait3 wait4 \
wcscoll wcsftime wcsxfrm wmemcmp writev _getpty)
+# Force lchmod off for Linux. Linux disallows changing the mode of symbolic
+# links. Some libc implementations have a stub lchmod implementation that always
+# returns an error.
+if test "$MACHDEP" != linux; then
+ AC_CHECK_FUNC(lchmod)
+fi
+
AC_CHECK_DECL(dirfd,
AC_DEFINE(HAVE_DIRFD, 1,
Define if you have the 'dirfd' function or macro.), ,