summaryrefslogtreecommitdiff
path: root/test/testatomic.c
diff options
context:
space:
mode:
authorJeff Trawick <trawick@apache.org>2003-11-16 23:58:48 +0000
committerJeff Trawick <trawick@apache.org>2003-11-16 23:58:48 +0000
commit0cf6173e42c4589201ca8e6cac1492ffee4d1538 (patch)
treea70c1d52a95d62a1518285ce024288139b67ffae /test/testatomic.c
parent21e41ca7a9ed42eef379a30374fba95b32e78efa (diff)
downloadapr-0cf6173e42c4589201ca8e6cac1492ffee4d1538.tar.gz
do the right thing on BEOS
avoid some duplication of platform knowledge git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@64752 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test/testatomic.c')
-rw-r--r--test/testatomic.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/test/testatomic.c b/test/testatomic.c
index 22e613b69..8f2b30109 100644
--- a/test/testatomic.c
+++ b/test/testatomic.c
@@ -64,7 +64,12 @@
#include <unistd.h>
#endif
-#if !(defined WIN32) && !(defined NETWARE)
+#if !(defined BEOS) && !(defined WIN32) && !(defined NETWARE) && !(defined __MVS__) && !(defined DARWIN)
+/* ugh... */
+#define HAVE_PTHREAD_SETCONCURRENCY
+#endif
+
+#ifdef HAVE_PTHREAD_SETCONCURRENCY
#include <pthread.h>
#endif
@@ -256,7 +261,7 @@ int main(int argc, char**argv)
}
printf("APR Atomic Test\n===============\n\n");
-#if !(defined WIN32) && !(defined NETWARE) && !(defined __MVS__) && !(defined DARWIN)
+#ifdef HAVE_PTHREAD_SETCONCURRENCY
pthread_setconcurrency(8);
#endif
printf("%-60s", "Initializing the context");