blob: dc88fd4014da91ae7637eb6e18afca6a704ad8ef [file] [log] [blame]
markchien932da862019-08-27 10:19:38 +08001//
2// Copyright (C) 2019 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17java_defaults {
18 name: "TetheringAndroidLibraryDefaults",
19 platform_apis: true,
20 srcs: [
21 "src/**/*.java",
markchien43e97e02019-09-03 15:58:06 +080022 ":framework-tethering-shared-srcs",
23 ":services-tethering-shared-srcs",
markchien932da862019-08-27 10:19:38 +080024 ],
25 static_libs: [
26 "androidx.annotation_annotation",
27 "tethering-client",
28 ],
29 manifest: "AndroidManifestBase.xml",
30}
31
32// Build tethering static library, used to compile both variants of the tethering.
33android_library {
34 name: "TetheringApiCurrentLib",
35 defaults: ["TetheringAndroidLibraryDefaults"],
36}
37
38// Common defaults for compiling the actual APK.
39java_defaults {
40 name: "TetheringAppDefaults",
41 platform_apis: true,
42 privileged: true,
43 resource_dirs: [
44 "res",
45 ],
46 optimize: {
47 proguard_flags_files: ["proguard.flags"],
48 },
49}
50
51// Non-updatable tethering running in the system server process for devices not using the module
52// TODO: build in-process tethering APK here.
53
54// Updatable tethering packaged as an application
55android_app {
56 name: "Tethering",
57 defaults: ["TetheringAppDefaults"],
58 static_libs: ["TetheringApiCurrentLib"],
59 certificate: "networkstack",
60 manifest: "AndroidManifest.xml",
61 use_embedded_native_libs: true,
62 // The permission configuration *must* be included to ensure security of the device
63 required: ["NetworkPermissionConfig"],
64}
markchien43e97e02019-09-03 15:58:06 +080065
66// This group will be removed when tethering migration is done.
67filegroup {
68 name: "tethering-services-srcs",
69 srcs: [
70 "src/com/android/server/connectivity/tethering/TetheringConfiguration.java",
71 ],
72}