1// Copyright (C) 2017 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 15package { 16 // See: http://go/android-license-faq 17 // A large-scale-change added 'default_applicable_licenses' to import 18 // all of the 'license_kinds' from "frameworks_compile_libbcc_license" 19 // to get the below license kinds: 20 // SPDX-license-identifier-Apache-2.0 21 default_applicable_licenses: ["frameworks_compile_libbcc_license"], 22} 23 24cc_library { 25 name: "libbcc", 26 vendor_available: true, 27 host_supported: true, 28 defaults: ["libbcc-defaults"], 29 30 srcs: [ 31 "BCCContext.cpp", 32 "BCCContextImpl.cpp", 33 "Compiler.cpp", 34 "CompilerConfig.cpp", 35 "FileBase.cpp", 36 "Initialization.cpp", 37 "RSAddDebugInfoPass.cpp", 38 "RSCompilerDriver.cpp", 39 "RSEmbedInfo.cpp", 40 "RSGlobalInfoPass.cpp", 41 "RSInvariant.cpp", 42 "RSInvokeHelperPass.cpp", 43 "RSIsThreadablePass.cpp", 44 "RSKernelExpand.cpp", 45 "RSScreenFunctionsPass.cpp", 46 "RSScriptGroupFusion.cpp", 47 "RSFunctionsList.cpp", 48 "RSX86CallConvPass.cpp", 49 "RSX86TranslateGEPPass.cpp", 50 "Script.cpp", 51 "Source.cpp", 52 ], 53 54 shared_libs: ["libbcinfo"], 55 56 header_libs: ["slang_headers"], 57 58 target: { 59 windows: { 60 enabled: true, 61 shared_libs: ["libLLVM_android"], 62 }, 63 darwin: { 64 shared_libs: ["libLLVM_android"], 65 }, 66 host_linux: { 67 static_libs: ["libLLVMLinker"], 68 allow_undefined_symbols: true, 69 }, 70 host: { 71 static_libs: [ 72 "libutils", 73 "libcutils", 74 "liblog", 75 ], 76 }, 77 android: { 78 shared_libs: [ 79 "libLLVM_android", 80 "libdl", 81 "liblog", 82 ], 83 }, 84 }, 85 86 product_variables: { 87 unbundled_build: { 88 // Don't build in unbundled branches 89 enabled: false, 90 }, 91 }, 92} 93