blob: 1bb1603c305192b88aa35c528c9c6cdca1504068 [file] [log] [blame]
Tao Bao30e31142019-04-09 00:12:30 -07001// 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_defaults {
Tao Baoca82fc92019-05-01 21:58:03 -070016 name: "releasetools_defaults",
Tao Bao30e31142019-04-09 00:12:30 -070017 version: {
18 py2: {
19 enabled: true,
20 embedded_launcher: false,
21 },
22 py3: {
Tao Baoca82fc92019-05-01 21:58:03 -070023 enabled: true,
24 embedded_launcher: false,
Tao Bao30e31142019-04-09 00:12:30 -070025 },
26 },
27}
28
29python_library_host {
30 name: "releasetools_lib",
Tao Baoca82fc92019-05-01 21:58:03 -070031 defaults: ["releasetools_defaults"],
Tao Bao30e31142019-04-09 00:12:30 -070032 srcs: [
33 "add_img_to_target_files.py",
34 "apex_utils.py",
35 "blockimgdiff.py",
36 "build_image.py",
37 "build_super_image.py",
38 "check_ota_package_signature.py",
39 "check_target_files_signatures.py",
40 "common.py",
41 "edify_generator.py",
42 "img_from_target_files.py",
Tianjie Xu41976c72019-07-03 13:57:01 -070043 "images.py",
Tao Bao30e31142019-04-09 00:12:30 -070044 "make_recovery_patch.py",
45 "merge_target_files.py",
46 "ota_from_target_files.py",
47 "ota_package_parser.py",
48 "rangelib.py",
Tao Baoc9c1b862019-06-26 14:54:14 -070049 "sign_apex.py",
Tao Bao30e31142019-04-09 00:12:30 -070050 "sign_target_files_apks.py",
51 "sparse_img.py",
52 "target_files_diff.py",
53 "validate_target_files.py",
54 "verity_utils.py",
55 ],
56}
57
Tao Baoca82fc92019-05-01 21:58:03 -070058python_defaults {
59 name: "releasetools_test_defaults",
60 defaults: ["releasetools_defaults"],
Tao Bao30e31142019-04-09 00:12:30 -070061 srcs: [
62 "test_*.py",
63 ],
64 libs: [
65 "releasetools_lib",
66 ],
67 data: [
68 "testdata/*",
69 ],
70 required: [
71 "otatools",
72 ],
Tao Baoca82fc92019-05-01 21:58:03 -070073}
74
75python_test_host {
76 name: "releasetools_test",
77 defaults: ["releasetools_test_defaults"],
78 main: "test_utils.py",
79 version: {
80 py2: {
81 enabled: true,
82 embedded_launcher: false,
83 },
84 py3: {
85 enabled: false,
86 embedded_launcher: false,
87 },
88 },
89 test_suites: ["general-tests"],
90}
91
92python_test_host {
93 name: "releasetools_py3_test",
94 defaults: ["releasetools_test_defaults"],
95 main: "test_utils.py",
96 version: {
97 py2: {
98 enabled: false,
99 embedded_launcher: false,
100 },
101 py3: {
102 enabled: true,
103 embedded_launcher: false,
104 },
105 },
Tao Bao30e31142019-04-09 00:12:30 -0700106 test_suites: ["general-tests"],
107}