Merge "Make libstatssocket shared" into rvc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
36a845dee4
@@ -31,7 +31,7 @@ aidl_interface {
|
|||||||
],
|
],
|
||||||
backend: {
|
backend: {
|
||||||
java: {
|
java: {
|
||||||
enabled: false, // the platform uses statsd_java_aidl
|
enabled: false, // framework-statsd and service-statsd use framework-statsd-aidl-sources
|
||||||
},
|
},
|
||||||
cpp: {
|
cpp: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
|
|||||||
@@ -48,9 +48,13 @@ cc_library_shared {
|
|||||||
"-Werror",
|
"-Werror",
|
||||||
],
|
],
|
||||||
shared_libs: [
|
shared_libs: [
|
||||||
"libbinder",
|
"libbinder_ndk",
|
||||||
"libutils",
|
"statsd-aidl-ndk_platform",
|
||||||
"libstatspull",
|
|
||||||
"libstatssocket",
|
|
||||||
],
|
],
|
||||||
}
|
static_libs: [
|
||||||
|
"libstatspull_private",
|
||||||
|
"libstatssocket_private",
|
||||||
|
"libutils",
|
||||||
|
"libcutils",
|
||||||
|
],
|
||||||
|
}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <binder/ProcessState.h>
|
#include <android/binder_process.h>
|
||||||
#include <jni.h>
|
#include <jni.h>
|
||||||
#include <log/log.h>
|
#include <log/log.h>
|
||||||
#include <stats_event.h>
|
#include <stats_event.h>
|
||||||
@@ -24,7 +24,6 @@
|
|||||||
#include <thread>
|
#include <thread>
|
||||||
|
|
||||||
using std::this_thread::sleep_for;
|
using std::this_thread::sleep_for;
|
||||||
using namespace android;
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
static int32_t sAtomTag;
|
static int32_t sAtomTag;
|
||||||
@@ -39,10 +38,8 @@ static void init() {
|
|||||||
if (!initialized) {
|
if (!initialized) {
|
||||||
initialized = true;
|
initialized = true;
|
||||||
// Set up the binder
|
// Set up the binder
|
||||||
sp<ProcessState> ps(ProcessState::self());
|
ABinderProcess_setThreadPoolMaxThreadCount(9);
|
||||||
ps->setThreadPoolMaxThreadCount(9);
|
ABinderProcess_startThreadPool();
|
||||||
ps->startThreadPool();
|
|
||||||
ps->giveThreadPoolName();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -302,11 +302,7 @@ cc_test {
|
|||||||
static_libs: [
|
static_libs: [
|
||||||
"libgmock",
|
"libgmock",
|
||||||
"libplatformprotos",
|
"libplatformprotos",
|
||||||
|
"libstatssocket_private",
|
||||||
// TODO(b/149842105): Make libstatssocket shared and remove libcutils once statsd_test is
|
|
||||||
// moved to the apex.
|
|
||||||
"libstatssocket",
|
|
||||||
"libcutils",
|
|
||||||
],
|
],
|
||||||
|
|
||||||
proto: {
|
proto: {
|
||||||
|
|||||||
@@ -121,7 +121,6 @@ cc_library {
|
|||||||
shared_libs: [
|
shared_libs: [
|
||||||
"liblog",
|
"liblog",
|
||||||
"libcutils",
|
"libcutils",
|
||||||
"libstatssocket",
|
|
||||||
],
|
],
|
||||||
apex_available: [
|
apex_available: [
|
||||||
"//apex_available:platform",
|
"//apex_available:platform",
|
||||||
@@ -129,5 +128,13 @@ cc_library {
|
|||||||
"com.android.os.statsd",
|
"com.android.os.statsd",
|
||||||
"test_com.android.os.statsd",
|
"test_com.android.os.statsd",
|
||||||
],
|
],
|
||||||
|
target: {
|
||||||
|
android: {
|
||||||
|
shared_libs: ["libstatssocket"],
|
||||||
|
},
|
||||||
|
host: {
|
||||||
|
static_libs: ["libstatssocket"],
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user