diff options
author | Yann Ylavic <ylavic@apache.org> | 2015-04-23 16:03:00 +0000 |
---|---|---|
committer | Yann Ylavic <ylavic@apache.org> | 2015-04-23 16:03:00 +0000 |
commit | efe392020c548e4f853c9f410903796b450cac3d (patch) | |
tree | 100012f4ba4afd5e4d62a4a3b50eb5169a2931d0 /configure.in | |
parent | 89e42a9c608a3bdf118d3cd1719e14c604645bd8 (diff) | |
download | apr-efe392020c548e4f853c9f410903796b450cac3d.tar.gz |
Switch to generic atomics for (unpatched) Solaris 10 not exporting some atomic
functions. PR 55418.
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1675668 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/configure.in b/configure.in index 231b70456..c22c45289 100644 --- a/configure.in +++ b/configure.in @@ -656,7 +656,20 @@ AC_ARG_ENABLE(nonportable-atomics, ], [case $host_cpu in i[[456]]86) force_generic_atomics=yes ;; - *) force_generic_atomics=no ;; + *) force_generic_atomics=no + case $host in + *solaris2.10*) + AC_TRY_COMPILE( + [#include <atomic.h>], + [void *ptr = NULL; atomic_cas_ptr(&ptr, NULL, NULL);],, + [force_generic_atomics=yes] + ) + if test $force_generic_atomics = yes; then + AC_MSG_NOTICE([nonportable atomic support disabled, system needs Patch-ID 118884 or 118885]) + fi + ;; + esac + ;; esac ]) |