You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by mt...@apache.org on 2011/04/16 23:38:31 UTC
svn commit: r1094059 -
/commons/sandbox/runtime/trunk/src/main/native/configure
Author: mturk
Date: Sat Apr 16 21:38:31 2011
New Revision: 1094059
URL: http://svn.apache.org/viewvc?rev=1094059&view=rev
Log:
Configure check for sem_open support. fixed
Modified:
commons/sandbox/runtime/trunk/src/main/native/configure
Modified: commons/sandbox/runtime/trunk/src/main/native/configure
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/configure?rev=1094059&r1=1094058&r2=1094059&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/configure (original)
+++ commons/sandbox/runtime/trunk/src/main/native/configure Sat Apr 16 21:38:31 2011
@@ -1095,16 +1095,15 @@ EOF
have_sem_open()
{
- do_printf 'Checking for %-32s' "sem_open support"
+ do_printf 'Checking for %-32s' "posix semaphore support"
cat > $cccsrc.c << EOF
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <semaphore.h>
-int main (){
-sem_open("/unknown$$", 0, 0, 0);
-if (errno==ENOSYS) puts("0");else puts("1");
-return 0;
+int rc=0;
+int main () {sem_open("/x$$x",0,0,0);
+if (errno!=ENOSYS)rc=1;printf("%d", rc);return 0;
}
EOF
rc=`test_compile x 0`