1// Copyright (C) 2019 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
15python_binary_host {
16  name: "generate-self-extracting-archive",
17  srcs: ["generate-self-extracting-archive.py"],
18  version: {
19    py2: {
20      enabled: true,
21    },
22    py3: {
23      enabled: false,
24    },
25  },
26}
27
28python_binary_host {
29  name: "post_process_props",
30  srcs: ["post_process_props.py"],
31  version: {
32    py2: {
33      enabled: false,
34    },
35    py3: {
36      enabled: true,
37    },
38  },
39}
40
41python_test_host {
42  name: "post_process_props_unittest",
43  main: "test_post_process_props.py",
44  srcs: [
45    "post_process_props.py",
46    "test_post_process_props.py",
47  ],
48  version: {
49    py2: {
50      enabled: false,
51    },
52    py3: {
53      enabled: true,
54    },
55  },
56  test_config: "post_process_props_unittest.xml",
57  test_suites: ["general-tests"],
58}
59
60python_binary_host {
61  name: "extract_kernel",
62  srcs: ["extract_kernel.py"],
63  version: {
64    py2: {
65      enabled: true,
66    },
67    py3: {
68      enabled: false,
69    },
70  },
71}
72
73genrule_defaults {
74  name: "extract_kernel_release_defaults",
75  tools: ["extract_kernel", "lz4"],
76  out: ["kernel_release.txt"],
77  cmd: "$(location) --tools lz4:$(location lz4) --input $(in) --output-release > $(out)"
78}
79