diff --git a/android/acl/acl.iml b/android/acl/acl.iml deleted file mode 100644 index 10af3d62a..000000000 --- a/android/acl/acl.iml +++ /dev/null @@ -1,291 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/android/acl/build.gradle b/android/acl/build.gradle index 1578f59ad..2b9abb5d1 100644 --- a/android/acl/build.gradle +++ b/android/acl/build.gradle @@ -24,14 +24,17 @@ android { versionCode 1 versionName "1.0" - testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" + // testIstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" externalNativeBuild { cmake { //arguments "-DANDROID_STL=gnustl_shared" //arguments "-DANDROID_STL=stl_shared" + arguments "-DANDROID_STL=c++_shared" + arguments "-DCMAKE_BUILD_TYPE=RELEASE" //cppFlags "-fexceptions" //abiFilters 'armeabi', 'arm64-v8a', 'armeabi-v7a', 'x86' //abiFilters 'x86', 'arm64-v8a' + //abiFilters 'arm64-v8a' abiFilters 'arm64-v8a', 'armeabi-v7a', 'x86', 'x86_64' //abiFilters 'arm64-v8a', 'armeabi-v7a' //abiFilters 'armeabi-v7a' diff --git a/lib_acl/CMakeLists.txt b/lib_acl/CMakeLists.txt index d80e430ee..5998f6683 100644 --- a/lib_acl/CMakeLists.txt +++ b/lib_acl/CMakeLists.txt @@ -75,11 +75,11 @@ endforeach() ############################################################################## -if (CMAKE_BUILD_TYPE STREQUAL "") - set(CMAKE_BUILD_TYPE "DEBUG") -else() - string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) -endif() +#if (CMAKE_BUILD_TYPE STREQUAL "") +# set(CMAKE_BUILD_TYPE "DEBUG") +#else() +# string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) +#endif() if (${UNIX_OS}) add_definitions( diff --git a/lib_acl_cpp/CMakeLists.txt b/lib_acl_cpp/CMakeLists.txt index c0bf80fd2..8b5861e01 100644 --- a/lib_acl_cpp/CMakeLists.txt +++ b/lib_acl_cpp/CMakeLists.txt @@ -108,11 +108,11 @@ if (${UNIX_OS}) ) endif() - if (CMAKE_BUILD_TYPE STREQUAL "") - set(CMAKE_BUILD_TYPE "DEBUG") - else() - string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) - endif() +# if (CMAKE_BUILD_TYPE STREQUAL "") +# set(CMAKE_BUILD_TYPE "DEBUG") +# else() +# string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) +# endif() if (CMAKE_BUILD_TYPE STREQUAL "RELEASE") add_definitions("-O2") diff --git a/lib_acl_cpp/samples/aio/http_aclient_ssl/main.cpp b/lib_acl_cpp/samples/aio/http_aclient_ssl/main.cpp index 59022b44c..247536194 100644 --- a/lib_acl_cpp/samples/aio/http_aclient_ssl/main.cpp +++ b/lib_acl_cpp/samples/aio/http_aclient_ssl/main.cpp @@ -71,7 +71,7 @@ public: protected: // @override - bool add_write_callback(void) + bool write_callback(void) { return true; } diff --git a/lib_acl_cpp/src/redis/redis_command.cpp b/lib_acl_cpp/src/redis/redis_command.cpp index 391316930..ad86a849f 100644 --- a/lib_acl_cpp/src/redis/redis_command.cpp +++ b/lib_acl_cpp/src/redis/redis_command.cpp @@ -48,7 +48,7 @@ redis_command::redis_command(redis_client* conn) , max_conns_(0) , slot_(-1) , redirect_max_(15) -, redirect_sleep_(1) +, redirect_sleep_(100) , slice_req_(false) , request_buf_(NULL) , request_obj_(NULL) @@ -90,7 +90,7 @@ redis_command::redis_command(redis_client_cluster* cluster, size_t max_conns) redirect_sleep_ = cluster->get_redirect_sleep(); } else { redirect_max_ = 15; - redirect_sleep_ = 1; + redirect_sleep_ = 100; } } diff --git a/lib_acl_cpp/src/stdlib/thread_mutex.cpp b/lib_acl_cpp/src/stdlib/thread_mutex.cpp index fba02bb31..c1eae4d53 100644 --- a/lib_acl_cpp/src/stdlib/thread_mutex.cpp +++ b/lib_acl_cpp/src/stdlib/thread_mutex.cpp @@ -97,12 +97,16 @@ bool thread_mutex::unlock(void) thread_mutex_guard::thread_mutex_guard(thread_mutex& mutex) : mutex_(mutex) { - acl_assert(mutex_.lock()); + if (!mutex_.lock()) { + logger_fatal("lock error=%s", last_serror()); + } } thread_mutex_guard::~thread_mutex_guard(void) { - acl_assert(mutex_.unlock()); + if (!mutex_.unlock()) { + logger_fatal("unlock error=%s", last_serror()); + } } } // namespace acl diff --git a/lib_fiber/c/xmake.lua b/lib_fiber/c/xmake.lua index 1e0e3a6de..756d05ddc 100644 --- a/lib_fiber/c/xmake.lua +++ b/lib_fiber/c/xmake.lua @@ -19,4 +19,5 @@ target("fiber") -- add flags add_cxflags("-std=gnu99") + add_defines("USE_JMP") diff --git a/lib_protocol/CMakeLists.txt b/lib_protocol/CMakeLists.txt index 87801e481..172463c26 100644 --- a/lib_protocol/CMakeLists.txt +++ b/lib_protocol/CMakeLists.txt @@ -72,11 +72,11 @@ if (${UNIX_OS}) add_definitions("-Wno-invalid-source-encoding") endif() - if (CMAKE_BUILD_TYPE STREQUAL "") - set(CMAKE_BUILD_TYPE "DEBUG") - else() - string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) - endif() +# if (CMAKE_BUILD_TYPE STREQUAL "") +# set(CMAKE_BUILD_TYPE "DEBUG") +# else() +# string(TOUPPER CMAKE_BUILD_TYPE CMAKE_BUILD_TYPE) +# endif() if (CMAKE_BUILD_TYPE STREQUAL "RELEASE") add_definitions("-O3")