Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 1 | # Copyright (C) 2018 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 | |
| 15 | import("../../gn/perfetto.gni") |
| 16 | |
| 17 | source_set("headers") { |
| 18 | deps = [ |
| 19 | "../../gn:default_deps", |
| 20 | ] |
| 21 | sources = [ |
Isabelle Taylor | f3edbfa | 2019-03-26 11:07:19 +0000 | [diff] [blame^] | 22 | "atrace_hal.h", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 23 | "health_hal.h", |
Esteban Talavera | 1fecac9 | 2019-01-09 16:06:29 +0000 | [diff] [blame] | 24 | "power_stats_hal.h", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 25 | ] |
| 26 | } |
| 27 | |
| 28 | # This target proxies calls to Android internal libraries that are not part of |
| 29 | # the NDK. See README.md. |
| 30 | source_set("android_internal") { |
| 31 | visibility = [ "//:libperfetto_android_internal" ] |
| 32 | deps = [ |
| 33 | ":headers", |
| 34 | "../../gn:default_deps", |
| 35 | ] |
| 36 | if (perfetto_build_with_android) { |
| 37 | sources = [ |
Isabelle Taylor | f3edbfa | 2019-03-26 11:07:19 +0000 | [diff] [blame^] | 38 | "atrace_hal.cc", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 39 | "health_hal.cc", |
Esteban Talavera | 1fecac9 | 2019-01-09 16:06:29 +0000 | [diff] [blame] | 40 | "power_stats_hal.cc", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 41 | ] |
| 42 | libs = [ |
| 43 | "android.hardware.health@2.0", |
Esteban Talavera | 1fecac9 | 2019-01-09 16:06:29 +0000 | [diff] [blame] | 44 | "android.hardware.power.stats@1.0", |
Isabelle Taylor | f3edbfa | 2019-03-26 11:07:19 +0000 | [diff] [blame^] | 45 | "android.hardware.atrace@1.0", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 46 | "base", |
| 47 | "log", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 48 | "hidlbase", |
| 49 | "hidltransport", |
Esteban Talavera | 1fecac9 | 2019-01-09 16:06:29 +0000 | [diff] [blame] | 50 | "hwbinder", |
Primiano Tucci | 676f0cc | 2018-12-03 20:03:26 +0100 | [diff] [blame] | 51 | "utils", |
| 52 | ] |
| 53 | } |
| 54 | |
| 55 | # This target should never depend on any other perfetto target to avoid ODR |
| 56 | # violation by doubly linking code in two .so(s) loaded in the same exe. |
| 57 | assert_no_deps = [ |
| 58 | "//src/base/*", |
| 59 | "//src/tracing/*", |
| 60 | "//include/*", |
| 61 | ] |
| 62 | } |