1/*
2 * Copyright (C) 2021 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
17package {
18    default_applicable_licenses: ["Android-Apache-2.0"],
19}
20
21python_defaults {
22    name: "modules-common-tools-python-defaults",
23    version: {
24        py2: {
25            enabled: false,
26        },
27        py3: {
28            enabled: true,
29            embedded_launcher: true,
30        },
31    },
32}
33
34python_binary_host {
35    name: "conv_classpaths_proto",
36    defaults: ["modules-common-tools-python-defaults"],
37    srcs: ["conv_classpaths_proto.py"],
38    libs: ["classpaths_proto_python"],
39}
40
41python_binary_host {
42    name: "gen_sdkinfo",
43    defaults: ["modules-common-tools-python-defaults"],
44    srcs: ["gen_sdkinfo.py"],
45    libs: ["sdk_proto_python"],
46}
47
48gensrcs {
49    name: "cur_sdkinfo_src",
50    srcs: [""],
51    tools: [ "gen_sdkinfo" ],
52    cmd: "$(location) -v 1 -o $(out)",
53}
54
55prebuilt_etc {
56    name: "current_sdkinfo",
57    src: ":cur_sdkinfo_src",
58    filename: "sdkinfo.pb",
59    installable: false,
60    visibility: [
61        "//art:__subpackages__",
62        "//external/conscrypt:__subpackages__",
63        "//frameworks/av/apex:__subpackages__",
64        "//packages/modules/Connectivity:__subpackages__",
65        "//packages/modules/IPsec/apex:__subpackages__",
66        "//packages/modules/Permission:__subpackages__",
67        "//packages/modules/Scheduling:__subpackages__",
68        "//packages/modules/SdkExtensions:__subpackages__",
69        "//packages/modules/StatsD:__subpackages__",
70        "//packages/providers/MediaProvider:__subpackages__",
71    ],
72}
73