Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 1 | // Copyright (C) 2016 The Android Open Source Project |
| 2 | // |
| 3 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | // you may not use this file except in compliance with the License. |
| 5 | // You may obtain a copy of the License at |
| 6 | // |
| 7 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | // |
| 9 | // Unless required by applicable law or agreed to in writing, software |
| 10 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | // See the License for the specific language governing permissions and |
| 13 | // limitations under the License. |
| 14 | |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 15 | |
Bob Badour | 8a6a2bc | 2021-02-12 17:07:05 -0800 | [diff] [blame] | 16 | package { |
| 17 | // See: http://go/android-license-faq |
| 18 | // A large-scale-change added 'default_applicable_licenses' to import |
| 19 | // all of the 'license_kinds' from "frameworks_base_license" |
| 20 | // to get the below license kinds: |
| 21 | // SPDX-license-identifier-Apache-2.0 |
| 22 | default_applicable_licenses: ["frameworks_base_license"], |
| 23 | } |
| 24 | |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 25 | cc_defaults { |
| 26 | name: "libincidentpriv_defaults", |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 27 | |
| 28 | cflags: [ |
| 29 | "-Wall", |
| 30 | "-Werror", |
| 31 | "-Wno-missing-field-initializers", |
| 32 | "-Wno-unused-variable", |
| 33 | "-Wunused-parameter", |
| 34 | ], |
| 35 | |
| 36 | shared_libs: [ |
| 37 | "libbinder", |
| 38 | "liblog", |
| 39 | "libutils", |
Joe Onorato | 99598ee | 2019-02-11 15:55:13 +0000 | [diff] [blame] | 40 | "libprotobuf-cpp-lite", |
| 41 | ], |
| 42 | |
| 43 | static_libs: [ |
| 44 | "libplatformprotos", |
| 45 | ], |
| 46 | |
| 47 | whole_static_libs: [ |
| 48 | "libincidentcompanion", |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 49 | ], |
| 50 | |
| 51 | aidl: { |
Joe Onorato | 99598ee | 2019-02-11 15:55:13 +0000 | [diff] [blame] | 52 | include_dirs: [ |
| 53 | "frameworks/base/core/java", |
| 54 | "frameworks/native/libs/incidentcompanion/binder", |
| 55 | ], |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 56 | export_aidl_headers: true, |
| 57 | }, |
| 58 | |
| 59 | srcs: [ |
| 60 | ":libincident_aidl", |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 61 | "src/IncidentReportArgs.cpp", |
| 62 | ], |
Spandan Das | d87b460 | 2021-09-24 19:05:32 +0000 | [diff] [blame] | 63 | min_sdk_version: "29", |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 64 | } |
| 65 | |
| 66 | cc_library_shared { |
| 67 | name: "libincidentpriv", |
| 68 | defaults: ["libincidentpriv_defaults"], |
| 69 | export_include_dirs: ["include_priv"], |
| 70 | } |
| 71 | |
| 72 | cc_library_shared { |
| 73 | name: "libincident", |
| 74 | |
| 75 | cflags: [ |
| 76 | "-Wall", |
| 77 | "-Werror", |
| 78 | "-Wno-missing-field-initializers", |
| 79 | "-Wno-unused-variable", |
| 80 | "-Wunused-parameter", |
| 81 | ], |
| 82 | |
| 83 | shared_libs: [ |
| 84 | "libbinder", |
| 85 | "liblog", |
| 86 | "libutils", |
| 87 | "libincidentpriv", |
| 88 | ], |
| 89 | |
| 90 | srcs: [ |
| 91 | "src/incident_report.cpp", |
| 92 | ], |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 93 | |
Colin Cross | bc2dc31 | 2018-10-26 22:34:06 -0700 | [diff] [blame] | 94 | export_include_dirs: ["include"], |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 95 | |
| 96 | stubs: { |
| 97 | symbol_file: "libincident.map.txt", |
| 98 | versions: [ |
| 99 | "30", |
| 100 | ], |
| 101 | }, |
Joe Onorato | 99598ee | 2019-02-11 15:55:13 +0000 | [diff] [blame] | 102 | } |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 103 | |
| 104 | cc_test { |
| 105 | name: "libincident_test", |
Joe Onorato | 084aa3c | 2020-03-20 16:25:14 -0700 | [diff] [blame] | 106 | test_config: "AndroidTest.xml", |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 107 | defaults: ["libincidentpriv_defaults"], |
Jeffrey Huang | d5fdf1e | 2021-04-23 11:52:40 -0700 | [diff] [blame] | 108 | test_suites: ["device-tests"], |
Ruchir Rastogi | dd5d287 | 2020-06-09 17:22:53 -0700 | [diff] [blame] | 109 | compile_multilib: "both", |
| 110 | multilib: { |
| 111 | lib64: { |
| 112 | suffix: "64", |
| 113 | }, |
| 114 | lib32: { |
| 115 | suffix: "32", |
| 116 | }, |
| 117 | }, |
| 118 | require_root: true, |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 119 | |
| 120 | include_dirs: [ |
| 121 | "frameworks/base/libs/incident/include", |
| 122 | "frameworks/base/libs/incident/include_priv", |
| 123 | ], |
| 124 | |
| 125 | srcs: [ |
| 126 | "tests/IncidentReportArgs_test.cpp", |
| 127 | "tests/IncidentReportRequest_test.cpp", |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 128 | ], |
| 129 | |
| 130 | shared_libs: [ |
| 131 | "libincident", |
| 132 | ], |
| 133 | |
| 134 | static_libs: [ |
| 135 | "libgmock", |
| 136 | ], |
Yike | ba21089 | 2022-09-30 10:34:57 +0800 | [diff] [blame] | 137 | |
| 138 | host_required: ["compatibility-tradefed"], |
Joe Onorato | 255ffff | 2020-01-17 01:30:02 -0800 | [diff] [blame] | 139 | } |