blob: 63e2748771027872018eec86f4fbc7a6cbed3090 [file] [log] [blame]
Wei Wang6b7561d2021-06-03 17:33:14 -07001// Copyright (C) 2021 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
19filegroup {
20 name: "nearby-service-srcs",
21 srcs: [
22 "java/**/*.java",
23 ],
24}
25
Weice57d88f62021-12-06 06:24:56 +000026filegroup {
27 name: "nearby-service-string-res",
28 srcs: [
29 "java/**/Constant.java",
30 ],
31}
32
33java_library {
34 name: "nearby-service-string",
35 srcs: [":nearby-service-string-res"],
36 sdk_version: "module_current",
37}
38
39
Wei Wang6b7561d2021-06-03 17:33:14 -070040// Main lib for nearby services.
41java_library {
42 name: "service-nearby",
43 srcs: [":nearby-service-srcs"],
44
45 defaults: [
46 "nearby-module-sdk-version-defaults",
47 "framework-system-server-module-defaults"
48 ],
49 libs: [
50 // pre-jarjar symbols are needed so that nearby-service can reference the original class
51 // names at compile time
52 "framework-nearby-pre-jarjar",
Chun Zhangbc34fdb2021-09-20 11:19:04 -070053 "error_prone_annotations",
54 ],
55 static_libs: [
Chun Zhangbc34fdb2021-09-20 11:19:04 -070056 "androidx.annotation_annotation",
Chun Zhang28660812021-09-22 20:48:39 -070057 "androidx.core_core",
Chun Zhangbbe60252021-09-21 22:05:03 -070058 "guava",
Chun Zhangfe6d0c12021-09-22 15:19:43 -070059 "libprotobuf-java-lite",
weicesunb989a182021-11-04 14:14:54 -070060 "fast-pair-lite-protos",
Chun Zhang00240662021-12-06 09:17:50 -080061 "modules-utils-build",
62 "modules-utils-handlerexecutor",
63 "modules-utils-preconditions",
64 "modules-utils-backgroundthread",
Wei Wang6b7561d2021-06-03 17:33:14 -070065 ],
66 sdk_version: "system_server_current",
67
68 installable: true,
69 optimize: {
70 enabled: true,
71 shrink: true,
Wei Wang72203032021-09-12 20:53:23 -070072 proguard_flags_files: ["proguard.flags"],
Wei Wang6b7561d2021-06-03 17:33:14 -070073 },
74 dex_preopt: {
75 enabled: false,
76 app_image: false,
77 },
78 visibility: [
79 "//packages/modules/Nearby/apex",
80 ],
81 apex_available: [
82 "com.android.nearby",
83 ],
Chun Zhang28417032021-09-20 14:10:38 -070084}