1cc_library_headers {
2    name: "libpdx_headers",
3    export_include_dirs: ["private"],
4    vendor_available: true,
5    min_sdk_version: "29",
6}
7
8cc_library_static {
9    name: "libpdx",
10    clang: true,
11    cflags: [
12        "-Wall",
13        "-Wextra",
14        "-Werror",
15        "-DLOG_TAG=\"libpdx\"",
16        "-DTRACE=0",
17    ],
18    header_libs: ["libpdx_headers"],
19    export_header_lib_headers: ["libpdx_headers"],
20    srcs: [
21        "client.cpp",
22        "service.cpp",
23        "service_dispatcher.cpp",
24        "status.cpp",
25    ],
26    shared_libs: [
27        "libbinder",
28        "libcutils",
29        "libutils",
30        "liblog",
31    ],
32}
33
34cc_test {
35    name: "pdx_tests",
36    clang: true,
37    cflags: [
38        "-Wall",
39        "-Wextra",
40        "-Werror",
41    ],
42    srcs: [
43        "client_tests.cpp",
44        "mock_tests.cpp",
45        "serialization_tests.cpp",
46        "service_tests.cpp",
47        "status_tests.cpp",
48        "thread_local_buffer_tests.cpp",
49        "variant_tests.cpp",
50    ],
51    static_libs: [
52        "libcutils",
53        "libgmock",
54        "libpdx",
55        "liblog",
56        "libutils",
57    ],
58    shared_libs: [
59        "libvndksupport",
60    ],
61}
62
63// Code analysis target.
64cc_test {
65    name: "pdx_encoder_performance_test",
66    clang: true,
67    cflags: [
68        "-Wall",
69        "-Wextra",
70        "-Werror",
71        "-O2",
72    ],
73    srcs: [
74        "encoder_performance_test.cpp",
75    ],
76    static_libs: [
77        "libpdx",
78    ],
79}
80