John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 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 | |
| 15 | java_defaults { |
| 16 | name: "trebuchet-defaults", |
| 17 | javacflags: [ |
| 18 | "-Xcoroutines=enable", |
| 19 | ], |
| 20 | } |
| 21 | |
| 22 | java_library_host { |
| 23 | name: "trebuchet-core", |
| 24 | defaults: ["trebuchet-defaults"], |
| 25 | srcs: [ |
| 26 | "core/common/src/main/**/*.kt", |
| 27 | "core/model/src/main/**/*.kt", |
| 28 | ], |
| 29 | libs: [ |
| 30 | "kotlin-reflect", |
| 31 | ], |
| 32 | no_framework_libs: true, |
| 33 | } |
| 34 | |
John Reck | 37fc1ac | 2018-10-03 19:11:41 -0700 | [diff] [blame] | 35 | java_library_host { |
| 36 | name: "trebuchet-startup-common", |
| 37 | defaults: ["trebuchet-defaults"], |
| 38 | srcs: [ |
| 39 | "trebuchet/startup-common/src/**/*.kt", |
| 40 | ], |
| 41 | libs: [ |
| 42 | "trebuchet-core", |
| 43 | ], |
| 44 | no_framework_libs: true, |
| 45 | } |
| 46 | |
John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 47 | java_test_host { |
| 48 | name: "trebuchet-core-tests", |
| 49 | defaults: ["trebuchet-defaults"], |
| 50 | srcs: [ |
| 51 | "core/common/src/test/**/*.kt", |
| 52 | ], |
| 53 | static_libs: [ |
| 54 | "trebuchet-core", |
| 55 | "kotlin-test", |
| 56 | ], |
| 57 | libs: [ |
| 58 | "junit", |
| 59 | "kotlin-reflect", |
| 60 | ], |
Eric Holk | acfb58a | 2019-03-05 12:31:54 -0800 | [diff] [blame] | 61 | test_suites: ["general-tests"], |
John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 62 | } |
| 63 | |
Eric Holk | 78fc9b1 | 2019-03-06 20:15:03 -0800 | [diff] [blame] | 64 | java_test_host { |
| 65 | name: "trebuchet-startup-common-tests", |
| 66 | defaults: ["trebuchet-defaults"], |
| 67 | srcs: [ |
| 68 | "trebuchet/startup-common/test/**/*.kt", |
| 69 | ], |
| 70 | static_libs: [ |
| 71 | "trebuchet-core", |
| 72 | "trebuchet-startup-common", |
| 73 | ], |
| 74 | libs: [ |
| 75 | "junit", |
| 76 | ], |
| 77 | test_suites: ["general-tests"], |
| 78 | } |
| 79 | |
John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 80 | java_binary_host { |
| 81 | name: "AnalyzerKt", |
| 82 | defaults: ["trebuchet-defaults"], |
| 83 | manifest: "trebuchet/analyzer/MANIFEST.mf", |
| 84 | srcs: [ |
| 85 | "trebuchet/analyzer/src/**/*.kt", |
| 86 | ], |
| 87 | static_libs: [ |
| 88 | "trebuchet-core", |
| 89 | ], |
| 90 | } |
| 91 | |
| 92 | java_binary_host { |
| 93 | name: "StartupAnalyzerKt", |
| 94 | defaults: ["trebuchet-defaults"], |
| 95 | manifest: "trebuchet/startup-analyzer/MANIFEST.mf", |
| 96 | srcs: [ |
| 97 | "trebuchet/startup-analyzer/src/**/*.kt", |
| 98 | ], |
| 99 | static_libs: [ |
| 100 | "trebuchet-core", |
John Reck | 37fc1ac | 2018-10-03 19:11:41 -0700 | [diff] [blame] | 101 | "trebuchet-startup-common" |
John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 102 | ], |
| 103 | } |
| 104 | |
| 105 | java_binary_host { |
Chris Wailes | 1c177ba | 2018-10-11 12:49:19 -0700 | [diff] [blame] | 106 | name: "StartupSummarizerKt", |
| 107 | defaults: ["trebuchet-defaults"], |
| 108 | manifest: "trebuchet/startup-summarizer/MANIFEST.mf", |
| 109 | srcs: [ |
| 110 | "trebuchet/startup-summarizer/src/**/*.kt", |
| 111 | ], |
| 112 | static_libs: [ |
| 113 | "trebuchet-core", |
| 114 | "trebuchet-startup-common" |
| 115 | ], |
| 116 | } |
| 117 | |
| 118 | java_binary_host { |
John Reck | fe7db0b | 2018-09-25 13:07:21 -0700 | [diff] [blame] | 119 | name: "traceutils", |
| 120 | defaults: ["trebuchet-defaults"], |
| 121 | manifest: "trebuchet/traceutils/MANIFEST.mf", |
| 122 | srcs: [ |
| 123 | "trebuchet/traceutils/src/**/*.kt", |
| 124 | ], |
| 125 | static_libs: [ |
| 126 | "trebuchet-core", |
| 127 | ], |
| 128 | } |
| 129 | |
| 130 | java_binary_host { |
| 131 | name: "traceviewer", |
| 132 | defaults: ["trebuchet-defaults"], |
| 133 | manifest: "trebuchet/viewer/MANIFEST.mf", |
| 134 | srcs: [ |
| 135 | "trebuchet/viewer/src/main/**/*.kt", |
| 136 | ], |
| 137 | static_libs: [ |
| 138 | "trebuchet-core", |
| 139 | ], |
| 140 | } |