1// Copyright (C) 2018 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 { 16 name: "aidegen_default", 17 pkg_path: "aidegen", 18 version: { 19 py2: { 20 enabled: false, 21 embedded_launcher: false, 22 }, 23 py3: { 24 enabled: true, 25 embedded_launcher: false, 26 }, 27 }, 28} 29 30python_binary_host { 31 name: "aidegen", 32 // Make aidegen's built name to aidegen-dev 33 suffix: "-dev", 34 defaults: ["aidegen_default"], 35 main: "aidegen_main.py", 36 srcs: [ 37 "**/*.py", 38 ], 39 libs: [ 40 "atest_module_info", 41 "asuite_cc_client", 42 ], 43 dist: { 44 targets: ["droidcore"], 45 }, 46} 47 48python_library_host { 49 name: "aidegen_lib", 50 defaults: ["aidegen_default"], 51 srcs: [ 52 "**/*.py", 53 ], 54 exclude_srcs: [ 55 "*_unittest.py", 56 "*/*_unittest.py", 57 ] 58} 59 60python_test_host { 61 name: "aidegen_unittests", 62 main: "aidegen_run_unittests.py", 63 pkg_path: "aidegen", 64 srcs: [ 65 "**/*.py", 66 ], 67 data: [ 68 "test_data/**/*", 69 ], 70 libs: [ 71 "py-mock", 72 "atest_module_info", 73 "asuite_cc_client", 74 ], 75 test_config: "aidegen_unittests.xml", 76 test_suites: ["general-tests"], 77 defaults: ["aidegen_default"], 78} 79