1// Copyright (C) 2024 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 15package { 16 default_applicable_licenses: ["Android-Apache-2.0"], 17} 18 19java_library { 20 name: "tracinglib-platform", 21 defaults: ["tracinglib-defaults"], 22 static_libs: [ 23 "kotlinx_coroutines_android", 24 "com_android_systemui_flags_lib", 25 ], 26 srcs: ["android/src-platform-api/**/*.kt"], 27} 28 29java_library { 30 name: "tracinglib-androidx", 31 defaults: ["tracinglib-defaults"], 32 static_libs: [ 33 "kotlinx_coroutines_android", 34 "com_android_systemui_flags_lib", 35 "androidx.tracing_tracing", 36 ], 37 srcs: ["android/src-public-api/**/*.kt"], 38 sdk_version: "31", 39 min_sdk_version: "19", 40 java_version: "17", 41} 42 43java_test_host { 44 name: "tracinglib-host-test", 45 defaults: ["tracinglib-defaults"], 46 srcs: [ 47 "host/src-fake/**/*.kt", 48 "host/test/**/*.kt", 49 ], 50 static_libs: [ 51 "kotlinx_coroutines", 52 "kotlinx_coroutines_test", 53 ], 54 libs: [ 55 "junit", 56 ], 57} 58 59java_defaults { 60 name: "tracinglib-defaults", 61 common_srcs: ["common/src/**/*.kt"], 62 kotlincflags: [ 63 "-Xjvm-default=all", 64 "-Xmulti-platform", 65 "-opt-in=kotlin.ExperimentalStdlibApi", 66 "-opt-in=kotlinx.coroutines.DelicateCoroutinesApi", 67 "-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi", 68 ], 69} 70