diff options
-rw-r--r-- | Android.mk | 2 | ||||
-rw-r--r-- | src/stressapptest_config_android.h | 3 | ||||
-rw-r--r-- | src/worker.cc | 2 |
3 files changed, 5 insertions, 2 deletions
@@ -22,6 +22,6 @@ LOCAL_MODULE:= stressapptest LOCAL_MODULE_TAGS := optional LOCAL_CFLAGS := -DHAVE_CONFIG_H -DANDROID -DNDEBUG -UDEBUG -DCHECKOPTS LOCAL_CPP_EXTENSION := .cc -LOCAL_CXX_STL := stlport +LOCAL_CXX_STL := libc++ include $(BUILD_EXECUTABLE) diff --git a/src/stressapptest_config_android.h b/src/stressapptest_config_android.h index 83a4866..3817bdf 100644 --- a/src/stressapptest_config_android.h +++ b/src/stressapptest_config_android.h @@ -57,6 +57,9 @@ /* Define to 1 if you have the <pthread.h> header file. */ #define HAVE_PTHREAD_H 1 +/* Android, why do you define _POSIX_BARRIERS when you have no _POSIX_BARRIERS?! */ +#undef _POSIX_BARRIERS + /* Define to 1 if you have the `rand_r' function. */ /* #undef HAVE_RAND_R */ diff --git a/src/worker.cc b/src/worker.cc index dcf4dcb..62b0ede 100644 --- a/src/worker.cc +++ b/src/worker.cc @@ -2066,7 +2066,7 @@ bool NetworkListenThread::Listen() { sa.sin_addr.s_addr = INADDR_ANY; sa.sin_port = htons(kNetworkPort); - if (-1 == bind(sock_, (struct sockaddr*)&sa, sizeof(struct sockaddr))) { + if (-1 == ::bind(sock_, (struct sockaddr*)&sa, sizeof(struct sockaddr))) { char buf[256]; sat_strerror(errno, buf, sizeof(buf)); logprintf(0, "Process Error: Cannot bind socket: %s\n", buf); |