Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 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 | |
| 15 | package cc |
| 16 | |
| 17 | import ( |
| 18 | "android/soong/android" |
| 19 | ) |
| 20 | |
Paul Duffin | 77980a8 | 2019-12-19 16:01:36 +0000 | [diff] [blame] | 21 | func RegisterRequiredBuildComponentsForTest(ctx android.RegistrationContext) { |
Paul Duffin | d686791 | 2019-12-19 14:38:36 +0000 | [diff] [blame] | 22 | RegisterPrebuiltBuildComponents(ctx) |
Paul Duffin | d686791 | 2019-12-19 14:38:36 +0000 | [diff] [blame] | 23 | android.RegisterPrebuiltMutators(ctx) |
Paul Duffin | 075c417 | 2019-12-19 19:06:13 +0000 | [diff] [blame] | 24 | |
Paul Duffin | 036e700 | 2019-12-19 19:16:28 +0000 | [diff] [blame] | 25 | RegisterCCBuildComponents(ctx) |
Paul Duffin | 2ee6979 | 2020-01-16 12:14:42 +0000 | [diff] [blame] | 26 | RegisterBinaryBuildComponents(ctx) |
Paul Duffin | 6c26dc7 | 2019-12-19 15:02:40 +0000 | [diff] [blame] | 27 | RegisterLibraryBuildComponents(ctx) |
| 28 | |
| 29 | ctx.RegisterModuleType("toolchain_library", ToolchainLibraryFactory) |
| 30 | ctx.RegisterModuleType("llndk_library", LlndkLibraryFactory) |
| 31 | ctx.RegisterModuleType("cc_object", ObjectFactory) |
Colin Cross | f28329d | 2020-02-15 11:00:10 -0800 | [diff] [blame] | 32 | ctx.RegisterModuleType("ndk_prebuilt_shared_stl", NdkPrebuiltSharedStlFactory) |
| 33 | ctx.RegisterModuleType("ndk_prebuilt_object", NdkPrebuiltObjectFactory) |
Paul Duffin | 77980a8 | 2019-12-19 16:01:36 +0000 | [diff] [blame] | 34 | } |
| 35 | |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 36 | func GatherRequiredDepsForTest(os android.OsType) string { |
| 37 | ret := ` |
| 38 | toolchain_library { |
| 39 | name: "libatomic", |
| 40 | vendor_available: true, |
| 41 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 42 | native_bridge_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 43 | src: "", |
| 44 | } |
| 45 | |
| 46 | toolchain_library { |
| 47 | name: "libcompiler_rt-extras", |
| 48 | vendor_available: true, |
| 49 | recovery_available: true, |
| 50 | src: "", |
| 51 | } |
| 52 | |
| 53 | toolchain_library { |
| 54 | name: "libclang_rt.builtins-arm-android", |
| 55 | vendor_available: true, |
| 56 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 57 | native_bridge_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 58 | src: "", |
| 59 | } |
| 60 | |
| 61 | toolchain_library { |
| 62 | name: "libclang_rt.builtins-aarch64-android", |
| 63 | vendor_available: true, |
| 64 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 65 | native_bridge_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 66 | src: "", |
| 67 | } |
| 68 | |
| 69 | toolchain_library { |
| 70 | name: "libclang_rt.builtins-i686-android", |
| 71 | vendor_available: true, |
| 72 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 73 | native_bridge_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 74 | src: "", |
| 75 | } |
| 76 | |
| 77 | toolchain_library { |
| 78 | name: "libclang_rt.builtins-x86_64-android", |
| 79 | vendor_available: true, |
| 80 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 81 | native_bridge_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 82 | src: "", |
| 83 | } |
| 84 | |
| 85 | toolchain_library { |
Mitch Phillips | da9a463 | 2019-07-15 09:34:09 -0700 | [diff] [blame] | 86 | name: "libclang_rt.fuzzer-arm-android", |
| 87 | vendor_available: true, |
| 88 | recovery_available: true, |
| 89 | src: "", |
| 90 | } |
| 91 | |
| 92 | toolchain_library { |
| 93 | name: "libclang_rt.fuzzer-aarch64-android", |
| 94 | vendor_available: true, |
| 95 | recovery_available: true, |
| 96 | src: "", |
| 97 | } |
| 98 | |
| 99 | toolchain_library { |
| 100 | name: "libclang_rt.fuzzer-i686-android", |
| 101 | vendor_available: true, |
| 102 | recovery_available: true, |
| 103 | src: "", |
| 104 | } |
| 105 | |
| 106 | toolchain_library { |
| 107 | name: "libclang_rt.fuzzer-x86_64-android", |
| 108 | vendor_available: true, |
| 109 | recovery_available: true, |
| 110 | src: "", |
| 111 | } |
| 112 | |
| 113 | toolchain_library { |
| 114 | name: "libclang_rt.fuzzer-x86_64", |
| 115 | vendor_available: true, |
| 116 | recovery_available: true, |
| 117 | src: "", |
| 118 | } |
| 119 | |
Paul Duffin | d686791 | 2019-12-19 14:38:36 +0000 | [diff] [blame] | 120 | // Needed for sanitizer |
| 121 | cc_prebuilt_library_shared { |
| 122 | name: "libclang_rt.ubsan_standalone-aarch64-android", |
| 123 | vendor_available: true, |
| 124 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 125 | system_shared_libs: [], |
Paul Duffin | d686791 | 2019-12-19 14:38:36 +0000 | [diff] [blame] | 126 | srcs: [""], |
| 127 | } |
| 128 | |
Mitch Phillips | da9a463 | 2019-07-15 09:34:09 -0700 | [diff] [blame] | 129 | toolchain_library { |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 130 | name: "libgcc", |
| 131 | vendor_available: true, |
| 132 | recovery_available: true, |
| 133 | src: "", |
| 134 | } |
| 135 | |
Yi Kong | acee27c | 2019-03-29 20:05:14 -0700 | [diff] [blame] | 136 | toolchain_library { |
| 137 | name: "libgcc_stripped", |
| 138 | vendor_available: true, |
| 139 | recovery_available: true, |
| 140 | src: "", |
| 141 | } |
| 142 | |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 143 | cc_library { |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 144 | name: "libc", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 145 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 146 | nocrt: true, |
Peter Collingbourne | e5ba286 | 2019-12-10 18:37:45 -0800 | [diff] [blame] | 147 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 148 | system_shared_libs: [], |
| 149 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 150 | stubs: { |
| 151 | versions: ["27", "28", "29"], |
| 152 | }, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 153 | } |
| 154 | llndk_library { |
| 155 | name: "libc", |
| 156 | symbol_file: "", |
| 157 | } |
| 158 | cc_library { |
| 159 | name: "libm", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 160 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 161 | nocrt: true, |
Peter Collingbourne | e5ba286 | 2019-12-10 18:37:45 -0800 | [diff] [blame] | 162 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 163 | system_shared_libs: [], |
| 164 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 165 | stubs: { |
| 166 | versions: ["27", "28", "29"], |
| 167 | }, |
| 168 | apex_available: [ |
| 169 | "//apex_available:platform", |
| 170 | "myapex" |
| 171 | ], |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 172 | } |
| 173 | llndk_library { |
| 174 | name: "libm", |
| 175 | symbol_file: "", |
| 176 | } |
| 177 | cc_library { |
| 178 | name: "libdl", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 179 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 180 | nocrt: true, |
Peter Collingbourne | e5ba286 | 2019-12-10 18:37:45 -0800 | [diff] [blame] | 181 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 182 | system_shared_libs: [], |
| 183 | recovery_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 184 | stubs: { |
| 185 | versions: ["27", "28", "29"], |
| 186 | }, |
| 187 | apex_available: [ |
| 188 | "//apex_available:platform", |
| 189 | "myapex" |
| 190 | ], |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 191 | } |
| 192 | llndk_library { |
| 193 | name: "libdl", |
| 194 | symbol_file: "", |
| 195 | } |
| 196 | cc_library { |
Jooyung Han | 097087b | 2019-10-22 19:32:18 +0900 | [diff] [blame] | 197 | name: "libft2", |
| 198 | no_libcrt: true, |
| 199 | nocrt: true, |
| 200 | system_shared_libs: [], |
| 201 | recovery_available: true, |
| 202 | } |
| 203 | llndk_library { |
| 204 | name: "libft2", |
| 205 | symbol_file: "", |
| 206 | vendor_available: false, |
| 207 | } |
| 208 | cc_library { |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 209 | name: "libc++_static", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 210 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 211 | nocrt: true, |
| 212 | system_shared_libs: [], |
| 213 | stl: "none", |
| 214 | vendor_available: true, |
| 215 | recovery_available: true, |
Inseob Kim | 89db15d | 2020-02-03 18:06:46 +0900 | [diff] [blame] | 216 | host_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 217 | } |
| 218 | cc_library { |
| 219 | name: "libc++", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 220 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 221 | nocrt: true, |
| 222 | system_shared_libs: [], |
| 223 | stl: "none", |
| 224 | vendor_available: true, |
| 225 | recovery_available: true, |
Inseob Kim | 89db15d | 2020-02-03 18:06:46 +0900 | [diff] [blame] | 226 | host_supported: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 227 | vndk: { |
| 228 | enabled: true, |
| 229 | support_system_process: true, |
| 230 | }, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 231 | apex_available: [ |
| 232 | "//apex_available:platform", |
| 233 | "myapex" |
| 234 | ], |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 235 | } |
| 236 | cc_library { |
Dan Albert | 2da19cb | 2019-07-24 12:17:40 -0700 | [diff] [blame] | 237 | name: "libc++demangle", |
| 238 | no_libcrt: true, |
| 239 | nocrt: true, |
| 240 | system_shared_libs: [], |
| 241 | stl: "none", |
| 242 | host_supported: false, |
| 243 | vendor_available: true, |
| 244 | recovery_available: true, |
| 245 | } |
| 246 | cc_library { |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 247 | name: "libunwind_llvm", |
Yi Kong | e7fe991 | 2019-06-02 00:53:50 -0700 | [diff] [blame] | 248 | no_libcrt: true, |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 249 | nocrt: true, |
| 250 | system_shared_libs: [], |
| 251 | stl: "none", |
| 252 | vendor_available: true, |
| 253 | recovery_available: true, |
| 254 | } |
| 255 | |
| 256 | cc_object { |
| 257 | name: "crtbegin_so", |
| 258 | recovery_available: true, |
| 259 | vendor_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 260 | native_bridge_supported: true, |
Jiyong Park | a7bc8ad | 2019-10-15 15:20:07 +0900 | [diff] [blame] | 261 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 262 | } |
| 263 | |
| 264 | cc_object { |
Colin Cross | 815daf9 | 2019-05-14 16:05:20 -0700 | [diff] [blame] | 265 | name: "crtbegin_dynamic", |
| 266 | recovery_available: true, |
| 267 | vendor_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 268 | native_bridge_supported: true, |
| 269 | stl: "none", |
Colin Cross | 815daf9 | 2019-05-14 16:05:20 -0700 | [diff] [blame] | 270 | } |
| 271 | |
| 272 | cc_object { |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 273 | name: "crtbegin_static", |
| 274 | recovery_available: true, |
| 275 | vendor_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 276 | native_bridge_supported: true, |
| 277 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 278 | } |
| 279 | |
| 280 | cc_object { |
| 281 | name: "crtend_so", |
| 282 | recovery_available: true, |
| 283 | vendor_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 284 | native_bridge_supported: true, |
Jiyong Park | a7bc8ad | 2019-10-15 15:20:07 +0900 | [diff] [blame] | 285 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 286 | } |
| 287 | |
| 288 | cc_object { |
| 289 | name: "crtend_android", |
| 290 | recovery_available: true, |
| 291 | vendor_available: true, |
Colin Cross | f9aabd7 | 2020-02-15 11:29:50 -0800 | [diff] [blame] | 292 | native_bridge_supported: true, |
| 293 | stl: "none", |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 294 | } |
| 295 | |
| 296 | cc_library { |
| 297 | name: "libprotobuf-cpp-lite", |
| 298 | } |
Colin Cross | f28329d | 2020-02-15 11:00:10 -0800 | [diff] [blame] | 299 | |
| 300 | cc_library { |
| 301 | name: "ndk_libunwind", |
| 302 | sdk_version: "current", |
| 303 | stl: "none", |
| 304 | system_shared_libs: [], |
| 305 | } |
| 306 | |
| 307 | cc_library { |
| 308 | name: "libc.ndk.current", |
| 309 | sdk_version: "current", |
| 310 | stl: "none", |
| 311 | system_shared_libs: [], |
| 312 | } |
| 313 | |
| 314 | cc_library { |
| 315 | name: "libm.ndk.current", |
| 316 | sdk_version: "current", |
| 317 | stl: "none", |
| 318 | system_shared_libs: [], |
| 319 | } |
| 320 | |
| 321 | cc_library { |
| 322 | name: "libdl.ndk.current", |
| 323 | sdk_version: "current", |
| 324 | stl: "none", |
| 325 | system_shared_libs: [], |
| 326 | } |
| 327 | |
| 328 | ndk_prebuilt_object { |
| 329 | name: "ndk_crtbegin_so.27", |
| 330 | sdk_version: "27", |
| 331 | } |
| 332 | |
| 333 | ndk_prebuilt_object { |
| 334 | name: "ndk_crtend_so.27", |
| 335 | sdk_version: "27", |
| 336 | } |
| 337 | |
| 338 | ndk_prebuilt_shared_stl { |
| 339 | name: "ndk_libc++_shared", |
| 340 | } |
| 341 | ` |
| 342 | |
Inseob Kim | c0907f1 | 2019-02-08 21:00:45 +0900 | [diff] [blame] | 343 | if os == android.Fuchsia { |
| 344 | ret += ` |
| 345 | cc_library { |
| 346 | name: "libbioniccompat", |
| 347 | stl: "none", |
| 348 | } |
| 349 | cc_library { |
| 350 | name: "libcompiler_rt", |
| 351 | stl: "none", |
| 352 | } |
| 353 | ` |
| 354 | } |
| 355 | return ret |
| 356 | } |
Colin Cross | 9a94287 | 2019-05-14 15:44:26 -0700 | [diff] [blame] | 357 | |
Colin Cross | f28329d | 2020-02-15 11:00:10 -0800 | [diff] [blame] | 358 | func GatherRequiredFilesForTest(fs map[string][]byte) { |
| 359 | fs["prebuilts/ndk/current/sources/cxx-stl/llvm-libc++/libs/arm64-v8a/libc++_shared.so"] = nil |
| 360 | fs["prebuilts/ndk/current/platforms/android-27/arch-arm/usr/lib/crtbegin_so.o"] = nil |
| 361 | fs["prebuilts/ndk/current/platforms/android-27/arch-arm/usr/lib/crtend_so.o"] = nil |
| 362 | fs["prebuilts/ndk/current/platforms/android-27/arch-arm64/usr/lib/crtbegin_so.o"] = nil |
| 363 | fs["prebuilts/ndk/current/platforms/android-27/arch-arm64/usr/lib/crtend_so.o"] = nil |
| 364 | fs["prebuilts/ndk/current/platforms/android-27/arch-x86/usr/lib/crtbegin_so.o"] = nil |
| 365 | fs["prebuilts/ndk/current/platforms/android-27/arch-x86/usr/lib/crtend_so.o"] = nil |
| 366 | fs["prebuilts/ndk/current/platforms/android-27/arch-x86_64/usr/lib64/crtbegin_so.o"] = nil |
| 367 | fs["prebuilts/ndk/current/platforms/android-27/arch-x86_64/usr/lib64/crtend_so.o"] = nil |
| 368 | } |
| 369 | |
Colin Cross | 98be1bb | 2019-12-13 20:41:13 -0800 | [diff] [blame] | 370 | func TestConfig(buildDir string, os android.OsType, env map[string]string, |
| 371 | bp string, fs map[string][]byte) android.Config { |
Colin Cross | 9a94287 | 2019-05-14 15:44:26 -0700 | [diff] [blame] | 372 | |
Colin Cross | 98be1bb | 2019-12-13 20:41:13 -0800 | [diff] [blame] | 373 | // add some modules that are required by the compiler and/or linker |
| 374 | bp = bp + GatherRequiredDepsForTest(os) |
| 375 | |
| 376 | mockFS := map[string][]byte{ |
| 377 | "foo.c": nil, |
| 378 | "foo.lds": nil, |
| 379 | "bar.c": nil, |
| 380 | "baz.c": nil, |
| 381 | "baz.o": nil, |
| 382 | "a.proto": nil, |
| 383 | "b.aidl": nil, |
| 384 | "sub/c.aidl": nil, |
| 385 | "my_include": nil, |
| 386 | "foo.map.txt": nil, |
| 387 | "liba.so": nil, |
| 388 | } |
| 389 | |
Colin Cross | f28329d | 2020-02-15 11:00:10 -0800 | [diff] [blame] | 390 | GatherRequiredFilesForTest(mockFS) |
| 391 | |
Colin Cross | 98be1bb | 2019-12-13 20:41:13 -0800 | [diff] [blame] | 392 | for k, v := range fs { |
| 393 | mockFS[k] = v |
| 394 | } |
| 395 | |
| 396 | var config android.Config |
| 397 | if os == android.Fuchsia { |
| 398 | config = android.TestArchConfigFuchsia(buildDir, env, bp, mockFS) |
| 399 | } else { |
| 400 | config = android.TestArchConfig(buildDir, env, bp, mockFS) |
| 401 | } |
| 402 | |
| 403 | return config |
| 404 | } |
| 405 | |
| 406 | func CreateTestContext() *android.TestContext { |
Colin Cross | 9a94287 | 2019-05-14 15:44:26 -0700 | [diff] [blame] | 407 | ctx := android.NewTestArchContext() |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 408 | ctx.RegisterModuleType("cc_fuzz", FuzzFactory) |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 409 | ctx.RegisterModuleType("cc_test", TestFactory) |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 410 | ctx.RegisterModuleType("llndk_headers", llndkHeadersFactory) |
Jooyung Han | b90e491 | 2019-12-09 18:21:48 +0900 | [diff] [blame] | 411 | ctx.RegisterModuleType("ndk_library", NdkLibraryFactory) |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 412 | ctx.RegisterModuleType("vendor_public_library", vendorPublicLibraryFactory) |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 413 | ctx.RegisterModuleType("filegroup", android.FileGroupFactory) |
| 414 | ctx.RegisterModuleType("vndk_prebuilt_shared", VndkPrebuiltSharedFactory) |
| 415 | ctx.RegisterModuleType("vndk_libraries_txt", VndkLibrariesTxtFactory) |
Paul Duffin | 77980a8 | 2019-12-19 16:01:36 +0000 | [diff] [blame] | 416 | RegisterRequiredBuildComponentsForTest(ctx) |
Colin Cross | e1bb5d0 | 2019-09-24 14:55:04 -0700 | [diff] [blame] | 417 | ctx.PreArchMutators(android.RegisterDefaultsPreArchMutators) |
Colin Cross | 4b49b76 | 2019-11-22 15:25:03 -0800 | [diff] [blame] | 418 | ctx.RegisterSingletonType("vndk-snapshot", VndkSnapshotSingleton) |
Inseob Kim | 8471cda | 2019-11-15 09:59:12 +0900 | [diff] [blame] | 419 | ctx.RegisterSingletonType("vendor-snapshot", VendorSnapshotSingleton) |
Colin Cross | 9a94287 | 2019-05-14 15:44:26 -0700 | [diff] [blame] | 420 | |
Colin Cross | 9a94287 | 2019-05-14 15:44:26 -0700 | [diff] [blame] | 421 | return ctx |
| 422 | } |