1// Copyright (C) 2020 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 default_applicable_licenses: ["external_libabigail_license"], 17} 18 19// Added automatically by a large-scale-change that took the approach of 20// 'apply every license found to every target'. While this makes sure we respect 21// every license restriction, it may not be entirely correct. 22// 23// e.g. GPL in an MIT project might only apply to the contrib/ directory. 24// 25// Please consider splitting the single license below into multiple licenses, 26// taking care not to lose any license_kind information, and overriding the 27// default license using the 'licenses: [...]' property on targets as needed. 28// 29// For unused files, consider creating a 'fileGroup' with "//visibility:private" 30// to attach the license to, and including a comment whether the files may be 31// used in the current project. 32// 33// large-scale-change included anything that looked like it might be a license 34// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc. 35// 36// Please consider removing redundant or irrelevant files from 'license_text:'. 37// 38// large-scale-change filtered out the below license kinds as false-positives: 39// SPDX-license-identifier-LGPL-3.0 40// See: http://go/android-license-faq 41license { 42 name: "external_libabigail_license", 43 visibility: [":__subpackages__"], 44 license_kinds: [ 45 "SPDX-license-identifier-Apache-2.0", 46 "SPDX-license-identifier-BSL-1.0", 47 "SPDX-license-identifier-MIT", 48 "legacy_unencumbered", 49 ], 50 license_text: [ 51 "LICENSE.txt", 52 "license-change-2020.txt", 53 ], 54} 55 56cc_defaults { 57 name: "libabigail_defaults", 58 cflags: [ 59 "-DABIGAIL_ROOT_SYSTEM_LIBDIR=\"lib\"", 60 "-fexceptions", 61 "-Wno-implicit-fallthrough", 62 ], 63 64 local_include_dirs: [ 65 "src", 66 "include", 67 ], 68 69 static_libs: [ 70 "libdw", 71 "libelf", 72 "libicuuc", 73 "libicuuc_stubdata", 74 "libxml2", 75 "libz", 76 ], 77 78 generated_headers: ["android_build_version"], 79 80 visibility: [ 81 "//visibility:private", 82 ], 83 compile_multilib: "64", 84 target: { 85 darwin: { 86 enabled: false, 87 }, 88 }, 89} 90 91cc_library_host_static { 92 name: "libabigail", 93 defaults: ["libabigail_defaults"], 94 srcs: [ 95 "src/*.cc", 96 ], 97 exclude_srcs: [ 98 "src/abg-viz-*", 99 ], 100} 101 102cc_binary_host { 103 name: "abidiff", 104 defaults: ["libabigail_defaults"], 105 srcs: [ 106 "tools/abidiff.cc", 107 ], 108 static_libs: [ 109 "libabigail", 110 ], 111} 112 113cc_binary_host { 114 name: "abidw", 115 defaults: ["libabigail_defaults"], 116 srcs: [ 117 "tools/abidw.cc", 118 ], 119 static_libs: [ 120 "libabigail", 121 ], 122} 123 124genrule { 125 name: "android_build_version", 126 cmd: "$(location) $(location .) $(out)", 127 out: [ 128 "android_build_version.h", 129 ], 130 srcs : ["."], 131 tool_files: [ 132 "android_build_version.sh" 133 ] 134} 135