diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2010-09-07 14:58:50 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2010-09-07 14:58:50 (GMT) |
commit | 15db1443aeac81fc8587409ab9eafbbde8c093e1 (patch) | |
tree | 4c62302380824bc03b327a63840ed0a8e2ec997d /configure.in | |
parent | 496153952a86e8f1c2e3be139ff96c3cca02ef38 (diff) | |
download | cpython-15db1443aeac81fc8587409ab9eafbbde8c093e1.zip cpython-15db1443aeac81fc8587409ab9eafbbde8c093e1.tar.gz cpython-15db1443aeac81fc8587409ab9eafbbde8c093e1.tar.bz2 |
Merged revisions 84584 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84584 | antoine.pitrou | 2010-09-07 16:52:42 +0200 (mar., 07 sept. 2010) | 4 lines
Issue #4026: Make the fcntl extension build under AIX.
Patch by Sébastien Sablé.
........
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/configure.in b/configure.in index 557be3a..99e8f9d 100644 --- a/configure.in +++ b/configure.in @@ -2642,14 +2642,29 @@ AC_TRY_COMPILE([ ) AC_MSG_CHECKING(for flock) +have_flock=no AC_TRY_COMPILE([ #include "confdefs.h" #include <sys/file.h> -], void* p = flock, +], void* p = flock, [ AC_DEFINE(HAVE_FLOCK, 1, Define if you have the 'flock' function.) - AC_MSG_RESULT(yes), - AC_MSG_RESULT(no) -) + have_flock=yes +]) +AC_MSG_RESULT($have_flock) + +if test "$have_flock" = yes ; then + AC_MSG_CHECKING(if flock requires additional libraries.) + AC_TRY_LINK([ + #include "confdefs.h" + #include <sys/file.h> + ], [flock(0, 0)], + AC_MSG_RESULT(no), [ + AC_MSG_RESULT(yes) + AC_CHECK_LIB(bsd,flock, [ + AC_DEFINE(FLOCK_NEEDS_LIBBSD, 1, Define if flock needs to be linked with bsd library.) + ]) + ]) +fi AC_MSG_CHECKING(for getpagesize) AC_TRY_COMPILE([ |