1package { 2 // See: http://go/android-license-faq 3 // A large-scale-change added 'default_applicable_licenses' to import 4 // all of the 'license_kinds' from "prebuilts_sdk_license" 5 // to get the below license kinds: 6 // SPDX-license-identifier-Apache-2.0 7 // SPDX-license-identifier-BSD 8 // SPDX-license-identifier-CPL-1.0 9 // SPDX-license-identifier-MIT 10 // SPDX-license-identifier-Unicode-DFS 11 // SPDX-license-identifier-W3C 12 default_applicable_licenses: ["prebuilts_sdk_license"], 13} 14 15cc_prebuilt_library_shared { 16 name: "libLLVM_android", 17 vendor_available: true, 18 host_supported: true, 19 // TODO(ccross): this is necessary because the prebuilt module must have 20 // all the variants that are in the source module. Ideally Soong's 21 // arch mutator should handle this. 22 // TODO(b/153609531): remove when no longer needed. 23 native_bridge_supported: true, 24 target: { 25 glibc_x86_64: { 26 srcs: ["linux/lib64/libLLVM_android.so"], 27 }, 28 musl_x86_64: { 29 // TODO(ccross): add a musl specific version when a musl SDK build exists 30 srcs: ["linux/lib64/libLLVM_android.so"], 31 }, 32 darwin_x86_64: { 33 srcs: ["darwin/lib64/libLLVM_android.dylib"], 34 }, 35 // TODO(ccross): this is necessary because the prebuilt module must have 36 // all the variants that are in the source module. Ideally Soong's 37 // arch mutator should handle this. 38 windows: { 39 enabled: true, 40 } 41 }, 42} 43 44cc_prebuilt_library_shared { 45 name: "libclang_android", 46 host_supported: true, 47 // TODO(ccross): this is necessary because the prebuilt module must have 48 // all the variants that are in the source module. Ideally Soong's 49 // arch mutator should handle this. 50 // TODO(b/153609531): remove when no longer needed. 51 native_bridge_supported: true, 52 target: { 53 glibc_x86_64: { 54 srcs: ["linux/lib64/libclang_android.so"], 55 }, 56 musl_x86_64: { 57 // TODO(ccross): add a musl specific version when a musl SDK build exists 58 srcs: ["linux/lib64/libclang_android.so"], 59 }, 60 darwin_x86_64: { 61 srcs: ["darwin/lib64/libclang_android.dylib"], 62 }, 63 // TODO(ccross): this is necessary because the prebuilt module must have 64 // all the variants that are in the source module. Ideally Soong's 65 // arch mutator should handle this. 66 windows: { 67 enabled: true, 68 } 69 }, 70} 71 72cc_prebuilt_binary { 73 name: "aapt2", 74 host_supported: true, 75 76 compile_multilib: "64", 77 prefer: true, 78 target: { 79 linux: { 80 srcs: ["linux/bin/aapt2"], 81 }, 82 darwin: { 83 srcs: ["darwin/bin/aapt2"], 84 }, 85 windows: { 86 srcs: ["windows/bin/aapt2.exe"], 87 }, 88 }, 89 enabled: false, 90 product_variables: { 91 always_use_prebuilt_sdks: { 92 enabled: true, 93 }, 94 }, 95} 96 97java_import { 98 name: "sdk-core-lambda-stubs", 99 jars: ["core-lambda-stubs.jar"], 100} 101 102genrule { 103 name: "build-tools-lld-linux", 104 visibility: ["//development/build"], 105 tools: ["soong_zip"], 106 cmd: "mkdir -p $(genDir)/out/{lld-bin,lib64} && " + 107 "cp $(location lld) $(genDir)/out/ && " + 108 "cp $(location lld-dummy) $(genDir)/out/arm-linux-androideabi-ld && " + 109 "cp $(location lld-dummy) $(genDir)/out/aarch64-linux-android-ld && " + 110 "cp $(location lld-dummy) $(genDir)/out/i686-linux-android-ld && " + 111 "cp $(location lld-dummy) $(genDir)/out/x86_64-linux-android-ld && " + 112 "cp $(location lld-dummy) $(genDir)/out/mipsel-linux-android-ld && " + 113 "cp $(location linux/lld-bin/lld) $(genDir)/out/lld-bin/ && " + 114 "cp $(location linux/lib64/libc++.so.1) $(genDir)/out/lib64/ && " + 115 "$(location soong_zip) -o $(out) -C $(genDir)/out -D $(genDir)/out", 116 srcs: [ 117 "lld", 118 "lld-dummy", 119 "linux/lld-bin/lld", 120 "linux/lib64/libc++.so.1", 121 ], 122 out: ["lld.zip"], 123} 124 125genrule { 126 name: "build-tools-lld-windows", 127 visibility: ["//development/build"], 128 tools: ["soong_zip"], 129 cmd: "mkdir -p $(genDir)/out/{lld-bin,lib64} && " + 130 "cp $(location lld-dummy) $(genDir)/out/arm-linux-androideabi-ld.exe && " + 131 "cp $(location lld-dummy) $(genDir)/out/aarch64-linux-android-ld.exe && " + 132 "cp $(location lld-dummy) $(genDir)/out/i686-linux-android-ld.exe && " + 133 "cp $(location lld-dummy) $(genDir)/out/x86_64-linux-android-ld.exe && " + 134 "cp $(location lld-dummy) $(genDir)/out/mipsel-linux-android-ld.exe && " + 135 "cp $(location windows/lld-bin/lld.exe) $(genDir)/out/lld-bin/ && " + 136 "cp $(location windows/lld-bin/libwinpthread-1.dll) $(genDir)/out/lld-bin/ && " + 137 "$(location soong_zip) -o $(out) -C $(genDir)/out -D $(genDir)/out", 138 srcs: [ 139 "lld-dummy", 140 "windows/lld-bin/lld.exe", 141 "windows/lld-bin/libwinpthread-1.dll", 142 ], 143 out: ["lld.zip"], 144} 145 146genrule { 147 name: "build-tools-lld-darwin", 148 visibility: ["//development/build"], 149 tools: ["soong_zip"], 150 cmd: "mkdir -p $(genDir)/out/{lld-bin,lib64} && " + 151 "cp $(location lld) $(genDir)/out/ && " + 152 "cp $(location lld-dummy) $(genDir)/out/arm-linux-androideabi-ld && " + 153 "cp $(location lld-dummy) $(genDir)/out/aarch64-linux-android-ld && " + 154 "cp $(location lld-dummy) $(genDir)/out/i686-linux-android-ld && " + 155 "cp $(location lld-dummy) $(genDir)/out/x86_64-linux-android-ld && " + 156 "cp $(location lld-dummy) $(genDir)/out/mipsel-linux-android-ld && " + 157 "cp $(location darwin/lld-bin/lld) $(genDir)/out/lld-bin/ && " + 158 "cp $(location darwin/lib64/libc++.1.dylib) $(genDir)/out/lib64/ && " + 159 "cp $(location darwin/lib64/libc++abi.1.dylib) $(genDir)/out/lib64/ && " + 160 "$(location soong_zip) -o $(out) -C $(genDir)/out -D $(genDir)/out", 161 srcs: [ 162 "lld", 163 "lld-dummy", 164 "darwin/lld-bin/lld", 165 "darwin/lib64/libc++.1.dylib", 166 "darwin/lib64/libc++abi.1.dylib", 167 ], 168 out: ["lld.zip"], 169} 170