47dea71b16
Also, add a link to the .clang-format-2 for this directory and clang format the files that changed. Bug: 31919199 Test: Boot bullhead. Test: Run unit tests on bullhead. There are a few that fail, but they Test: failed before and are not a result of this change. Change-Id: I3d3b2111f6f6bf8a0d7039295d34d5168c191651
86 lines
1.9 KiB
Text
86 lines
1.9 KiB
Text
cc_defaults {
|
|
name: "libmemunreachable_defaults",
|
|
|
|
cflags: [
|
|
"-Wall",
|
|
"-Wextra",
|
|
"-Werror",
|
|
],
|
|
clang: true,
|
|
shared_libs: [
|
|
"libbase",
|
|
],
|
|
|
|
target: {
|
|
android: {
|
|
static_libs: ["libasync_safe"],
|
|
},
|
|
host: {
|
|
shared_libs: ["liblog"],
|
|
}
|
|
},
|
|
}
|
|
|
|
cc_library_shared {
|
|
name: "libmemunreachable",
|
|
defaults: ["libmemunreachable_defaults"],
|
|
srcs: [
|
|
"Allocator.cpp",
|
|
"HeapWalker.cpp",
|
|
"LeakFolding.cpp",
|
|
"LeakPipe.cpp",
|
|
"LineBuffer.cpp",
|
|
"MemUnreachable.cpp",
|
|
"ProcessMappings.cpp",
|
|
"PtracerThread.cpp",
|
|
"ThreadCapture.cpp",
|
|
],
|
|
|
|
static_libs: [
|
|
"libc_malloc_debug_backtrace",
|
|
],
|
|
// Only need this for arm since libc++ uses its own unwind code that
|
|
// doesn't mix with the other default unwind code.
|
|
arch: {
|
|
arm: {
|
|
static_libs: ["libunwind_llvm"],
|
|
},
|
|
},
|
|
export_include_dirs: ["include"],
|
|
local_include_dirs: ["include"],
|
|
}
|
|
|
|
cc_test {
|
|
name: "memunreachable_test",
|
|
defaults: ["libmemunreachable_defaults"],
|
|
host_supported: true,
|
|
srcs: [
|
|
"tests/Allocator_test.cpp",
|
|
"tests/HeapWalker_test.cpp",
|
|
"tests/LeakFolding_test.cpp",
|
|
],
|
|
|
|
target: {
|
|
android: {
|
|
srcs: [
|
|
"tests/DisableMalloc_test.cpp",
|
|
"tests/MemUnreachable_test.cpp",
|
|
"tests/ThreadCapture_test.cpp",
|
|
],
|
|
shared_libs: [
|
|
"libmemunreachable",
|
|
],
|
|
},
|
|
host: {
|
|
srcs: [
|
|
"Allocator.cpp",
|
|
"HeapWalker.cpp",
|
|
"LeakFolding.cpp",
|
|
"tests/HostMallocStub.cpp",
|
|
],
|
|
},
|
|
darwin: {
|
|
enabled: false,
|
|
},
|
|
},
|
|
}
|