• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2018 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
21cc_library_static {
22    name: "lib_apex_manifest_proto",
23    host_supported: true,
24    proto: {
25        export_proto_headers: true,
26        type: "full",
27    },
28    srcs: ["apex_manifest.proto"],
29}
30
31cc_library_static {
32    name: "lib_apex_manifest_proto_lite",
33    host_supported: true,
34    recovery_available: true,
35    proto: {
36        export_proto_headers: true,
37        type: "lite",
38    },
39    srcs: ["apex_manifest.proto"],
40    apex_available: [
41        "//apex_available:platform",
42        "com.android.runtime",
43    ],
44}
45
46python_library_host {
47    name: "apex_manifest_proto",
48    srcs: [
49        "apex_manifest.proto",
50    ],
51    proto: {
52        canonical_path_from_root: false,
53    },
54}
55
56python_library_host {
57    name: "apex_build_info_proto",
58    srcs: [
59        "apex_build_info.proto",
60    ],
61    proto: {
62        canonical_path_from_root: false,
63    },
64}
65
66java_library_static {
67    name: "apex_manifest_proto_java",
68    host_supported: true,
69    device_supported: false,
70    proto: {
71        type: "full",
72    },
73    srcs: ["apex_manifest.proto"],
74}
75
76cc_library_static {
77    name: "lib_apex_session_state_proto",
78    host_supported: true,
79    proto: {
80        export_proto_headers: true,
81        type: "full",
82    },
83    srcs: ["session_state.proto"],
84}
85
86genrule {
87    name: "apex-protos",
88    tools: ["soong_zip"],
89    dist: {
90        targets: ["apexer_tools"],
91    },
92    srcs: [
93        "apex_manifest.proto",
94        "apex_build_info.proto",
95    ],
96    out: ["apex-protos.zip"],
97    cmd: "mkdir $(genDir)/protos && " +
98        "cp $(in) $(genDir)/protos && " +
99        "$(location soong_zip) -o $(out) -C $(genDir)/protos -D $(genDir)/protos",
100}
101