blob: 5984093ed3761bd6c0e7716c6475d4256d0ffde6 [file] [log] [blame]
Jiyong Park522ae9a2017-06-23 21:23:16 +09001//
2// Copyright (C) 2017 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15
16cc_defaults {
17 name: "dumpstate_defaults",
18 cflags: [
19 "-Wall",
20 "-Werror",
21 "-Wno-missing-field-initializers",
22 "-Wno-unused-variable",
23 "-Wunused-parameter",
24 ],
25}
26
27cc_library_headers {
28 name: "dumpstate_headers",
29 vendor_available: true,
30 export_include_dirs: ["."],
31 header_libs: [
32 "libbase_headers",
33 "libutils_headers",
34 ],
35 export_header_lib_headers: [
36 "libbase_headers",
37 "libutils_headers",
38 ],
39}
40
41cc_library_shared {
42 name: "libdumpstateutil",
43 defaults: ["dumpstate_defaults"],
44 vendor_available: true,
45 header_libs: ["dumpstate_headers"],
46 export_header_lib_headers: ["dumpstate_headers"],
47 srcs: [
48 "DumpstateInternal.cpp",
49 "DumpstateUtil.cpp",
50 ],
51 shared_libs: [
52 "libbase",
53 "liblog",
54 ],
55}
56
57cc_library_shared {
58 name: "libdumpstateaidl",
59 defaults: ["dumpstate_defaults"],
60 shared_libs: [
61 "libbinder",
62 "libutils",
63 ],
64 aidl: {
65 local_include_dirs: ["binder"],
66 export_aidl_headers: true,
67 },
68 srcs: [
69 "binder/android/os/IDumpstate.aidl",
70 "binder/android/os/IDumpstateListener.aidl",
71 "binder/android/os/IDumpstateToken.aidl",
72 ],
73}
74
75cc_binary {
76 name: "dumpstate",
77 defaults: ["dumpstate_defaults"],
78 header_libs: ["dumpstate_headers"],
79 shared_libs: [
80 "android.hardware.dumpstate@1.0",
81 "libziparchive",
82 "libbase",
83 "libbinder",
84 "libcrypto",
85 "libcutils",
86 "libdebuggerd_client",
87 "libdumpstateaidl",
88 "libdumpstateutil",
89 "libhidlbase",
90 "libhidltransport",
91 "liblog",
92 "libutils",
93 ],
94 srcs: [
95 "DumpstateInternal.cpp",
96 "DumpstateService.cpp",
97 "utils.cpp",
98 "dumpstate.cpp",
99 ],
100 init_rc: ["dumpstate.rc"],
101}
102
103cc_test {
104 name: "dumpstate_test",
105 defaults: ["dumpstate_defaults"],
106 header_libs: ["dumpstate_headers"],
107 shared_libs: [
108 "libziparchive",
109 "libbase",
110 "libbinder",
111 "libcutils",
112 "libdebuggerd_client",
113 "libdumpstateaidl",
114 "libdumpstateutil",
115 "libhidlbase",
116 "libhidltransport",
117 "liblog",
118 "libutils",
119 ],
120 srcs: [
121 "DumpstateInternal.cpp",
122 "DumpstateService.cpp",
123 "utils.cpp",
124 "tests/dumpstate_test.cpp",
125 ],
126 static_libs: ["libgmock"],
127}