加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Android.bp 19.28 KB
一键复制 编辑 原始数据 按行查看 历史
jeremy_cz 提交于 2021-08-19 07:40 . fix build failure for Android and QNX
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699
//=====================================================================================
// makefile to build fdbus in aosp source tree |
//=====================================================================================
//=====================================================================================
// build libcommon-base.so |
//=====================================================================================
SRC_FILES = [
"fdbus/CBaseClient.cpp",
"fdbus/CFdbBaseObject.cpp",
"fdbus/CFdbMessage.cpp",
"fdbus/CFdbSimpleSerializer.cpp",
"fdbus/CBaseEndpoint.cpp",
"fdbus/CFdbCJsonMsgBuilder.cpp",
"fdbus/CFdbSessionContainer.cpp",
"log/CLogProducer.cpp",
"fdbus/CBaseServer.cpp",
"fdbus/CFdbContext.cpp",
"fdbus/CFdbBaseContext.cpp",
"fdbus/CFdbSession.cpp",
"fdbus/CFdbMsgDispatcher.cpp",
"fdbus/CEventSubscribeHandle.cpp",
"fdbus/CFdbUDPSession.cpp",
"fdbus/CBaseSession.cpp",
"fdbus/CFdbWatchdog.cpp",
"fdbus/CFdbEventRouter.cpp",
"platform/CEventFd_eventfd.cpp",
"platform/linux/CBaseMutexLock.cpp",
"platform/linux/CBasePipe.cpp",
"platform/linux/CBaseSemaphore.cpp",
"platform/linux/CBaseSysDep.cpp",
"platform/linux/CBaseThread.cpp",
"platform/socket/CBaseSocketFactory.cpp",
"platform/socket/linux/CLinuxSocket.cpp",
"platform/socket/sckt-0.5/sckt.cpp",
"security/CApiSecurityConfig.cpp",
"security/CFdbToken.cpp",
"security/CFdbusSecurityConfig.cpp",
"security/CHostSecurityConfig.cpp",
"security/CServerSecurityConfig.cpp",
"utils/fdb_option_parser.cpp",
"worker/CBaseEventLoop.cpp",
"worker/CBaseWorker.cpp",
"worker/CFdEventLoop.cpp",
"worker/CThreadEventLoop.cpp",
"worker/CSysFdWatch.cpp",
"utils/CBaseNameProxy.cpp",
"fdbus/CIntraNameProxy.cpp",
"server/CAddressAllocator.cpp",
"log/CLogPrinter.cpp",
"log/CFdbLogCache.cpp",
"utils/cJSON/cJSON.c",
"fdbus/CFdbAFComponent.cpp",
]
FDB_PROTO_DIR = "example/idl"
FDB_IDL_GEN_DIR = "vendor/bosch/fdbus/" + FDB_PROTO_DIR
cc_library_shared {
name: "libcommon-base",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
"-DCONFIG_SOCKET_CONNECT_TIMEOUT=0",
"-DCONFIG_LOG_TO_STDOUT",
"-DCONFIG_FDB_NO_RTTI",
"-DCONFIG_FDB_MESSAGE_METADATA",
"-DFDB_CONFIG_UDS_ABSTRACT",
"-DCFG_ALLOC_PORT_BY_SYSTEM",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
"-DCONFIG_SOCKET_CONNECT_TIMEOUT=0",
"-DCONFIG_LOG_TO_STDOUT",
"-DCONFIG_FDB_MESSAGE_METADATA",
"-DFDB_CONFIG_UDS_ABSTRACT",
"-DCFG_ALLOC_PORT_BY_SYSTEM",
],
shared_libs: [
"liblog",
"libutils",
],
srcs: SRC_FILES,
export_include_dirs: ["public"],
local_include_dirs: [],
}
//=====================================================================================
// build libfdbus-jni.so |
//=====================================================================================
cc_library_shared {
name: "libfdbus-jni",
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
"-DCFG_JNI_ANDROID",
"-DFDB_CFG_KEEP_ENV_TYPE",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
"-DCFG_JNI_ANDROID",
],
srcs: [
"jni/src/cpp/CJniClient.cpp",
"jni/src/cpp/CJniMessage.cpp",
"jni/src/cpp/CJniServer.cpp",
"jni/src/cpp/FdbusGlobal.cpp",
"jni/src/cpp/CJniAFComponent.cpp",
],
shared_libs: ["libcommon-base"],
include_dirs: [
"frameworks/base/core/jni",
"frameworks/base/core/jni/include",
],
}
//=====================================================================================
// build fdbus-jni.jar |
//=====================================================================================
java_library {
sdk_version: "current",
name: "fdbus-jni",
srcs: ["jni/src/java/ipc/fdbus/**/*.java"],
}
//=====================================================================================
// build fdbus-java-client.jar (java test client) |
//=====================================================================================
java_library {
sdk_version: "current",
name: "fdbus-java-client",
proto: {
type: "lite",
},
srcs: [
"jni/test/MediaClient.java",
"jni/test/FdbusProtoBuilder.java",
"jni/test/CPerson.java",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
libs: [
"fdbus-jni",
"libprotobuf-java-lite",
],
}
//=====================================================================================
// build fdbus-java-server.jar (java test server) |
//=====================================================================================
java_library {
sdk_version: "current",
name: "fdbus-java-server",
proto: {
type: "lite",
},
srcs: [
"jni/test/MediaServer.java",
"jni/test/FdbusProtoBuilder.java",
"jni/test/CPerson.java",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
libs: [
"fdbus-jni",
"libprotobuf-java-lite",
],
}
//=====================================================================================
// build fdbus-java-appcomp-client.jar (java test client) |
//=====================================================================================
java_library {
sdk_version: "current",
name: "fdbus-java-appcomp-client",
proto: {
type: "lite",
},
srcs: [
"jni/test/AFComponentClient.java",
"jni/test/FdbusProtoBuilder.java",
"jni/test/CPerson.java",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
libs: [
"fdbus-jni",
"libprotobuf-java-lite",
],
}
//=====================================================================================
// build fdbus-java-appcomp-server.jar (java test server) |
//=====================================================================================
java_library {
sdk_version: "current",
name: "fdbus-java-appcomp-server",
proto: {
type: "lite",
},
srcs: [
"jni/test/AFComponentServer.java",
"jni/test/FdbusProtoBuilder.java",
"jni/test/CPerson.java",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
libs: [
"fdbus-jni",
"libprotobuf-java-lite",
],
}
//=====================================================================================
// build name-server |
//=====================================================================================
cc_binary {
name: "name-server",
vendor_available: true,
init_rc: ["fdbus-name-server.rc"],
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"server/main_ns.cpp",
"server/CNameServer.cpp",
"server/CInterNameProxy.cpp",
"server/CIntraHostProxy.cpp",
"server/CBaseHostProxy.cpp",
"server/CSvcAddrUtils.cpp",
"security/CServerSecurityConfig.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build host-server |
//=====================================================================================
cc_binary {
name: "host-server",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DFDB_CFG_SOCKET_PATH=\"/data/misc/fdbus\"",
],
srcs: [
"server/main_hs.cpp",
"server/CHostServer.cpp",
"security/CHostSecurityConfig.cpp",
"server/CInterHostProxy.cpp",
"server/CBaseHostProxy.cpp",
"server/CSvcAddrUtils.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build lssvc (list service) |
//=====================================================================================
cc_binary {
name: "lssvc",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: ["server/main_ls.cpp"],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build lshost (list host) |
//=====================================================================================
cc_binary {
name: "lshost",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: ["server/main_lh.cpp"],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build lsclt (list client) |
//=====================================================================================
cc_binary {
name: "lsclt",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: ["server/main_lc.cpp"],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build logsvc (log service) |
//=====================================================================================
cc_binary {
name: "logsvc",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"log/main_log_server.cpp",
"log/CLogFileManager.cpp",
"log/fdb_log_config.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build logviewer (log viewer) |
//=====================================================================================
cc_binary {
name: "logviewer",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"log/main_log_client.cpp",
"log/fdb_log_config.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build ntfcenter (notification center) |
//=====================================================================================
cc_binary {
name: "ntfcenter",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"server/main_nc.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build lsevt (list cached events) |
//=====================================================================================
cc_binary {
name: "lsevt",
vendor_available: true,
cppflags: [
"-frtti",
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"server/main_le.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
FDB_IDL_EXAMPLE_H = "<" + FDB_IDL_GEN_DIR + "/common.base.Example.pb.h>"
//=====================================================================================
// build fdbtest_client (native test) |
//=====================================================================================
cc_binary {
name: "fdbtest_client",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
"-DFDBUS_PROTO_FULL_FEATURE",
"-DFDB_IDL_EXAMPLE_H=" + FDB_IDL_EXAMPLE_H,
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"example/client-server/fdb_test_client.cpp",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
shared_libs: [
"libprotobuf-cpp-full",
"libcommon-base",
"liblog",
"libutils",
],
proto: {
type: "full",
},
}
//=====================================================================================
// build fdbtest_server (native test) |
//=====================================================================================
cc_binary {
name: "fdbtest_server",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
"-DFDBUS_PROTO_FULL_FEATURE",
"-DFDB_IDL_EXAMPLE_H=" + FDB_IDL_EXAMPLE_H,
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"example/client-server/fdb_test_server.cpp",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
shared_libs: [
"libprotobuf-cpp-full",
"libcommon-base",
"liblog",
"libutils",
],
proto: {
type: "full",
},
}
//=====================================================================================
// build fdbxclient (throughput test client) |
//=====================================================================================
cc_binary {
name: "fdbxclient",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: ["server/main_xclient.cpp"],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build fdbxserver (throughput test server) |
//=====================================================================================
cc_binary {
name: "fdbxserver",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: ["server/main_xserver.cpp"],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
}
//=====================================================================================
// build fdbntfcentertest (test for notification center) |
//=====================================================================================
cc_binary {
name: "fdbntfcentertest",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
"-DFDBUS_PROTO_FULL_FEATURE",
"-DFDB_IDL_EXAMPLE_H=" + FDB_IDL_EXAMPLE_H,
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"example/notification-center/fdb_test_notification_center.cpp",
FDB_PROTO_DIR + "/common.base.Example.proto",
],
shared_libs: [
"libprotobuf-cpp-full",
"libcommon-base",
"liblog",
"libutils",
],
proto: {
type: "full",
},
}
//=====================================================================================
// build app framework (native test) |
//=====================================================================================
cc_binary {
name: "fdbappfwtest",
vendor_available: true,
cppflags: [
"-fexceptions",
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
"-DFDBUS_PROTO_FULL_FEATURE",
],
cflags: [
"-Wno-unused-parameter",
"-D__LINUX__",
"-DCONFIG_DEBUG_LOG",
],
srcs: [
"example/app-framework/fdb_appfw_test.cpp",
],
shared_libs: [
"libcommon-base",
"liblog",
"libutils",
],
proto: {
type: "full",
},
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化