blob: 0c64b7df9fa321be9f6076ecc87498fa79e674fa [file] [log] [blame]
Colin Cross1f7f3bd2016-07-27 10:12:38 -07001//
2// Copyright (C) 2014 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17cc_library {
18 name: "libsigchain",
19 host_supported: true,
20 defaults: ["art_defaults"],
21 shared: {
22 srcs: ["sigchain_dummy.cc"],
23 },
24 static: {
25 srcs: ["sigchain.cc"],
26 },
27 target: {
28 host: {
29 host_ldlibs: ["-ldl"],
30 },
31 android: {
32 shared_libs: ["liblog"],
33 },
34 },
Andreas Gampe89b85842017-05-10 09:47:55 -070035 // Sigchainlib is whole-statically linked into binaries. For Android.mk-based binaries,
36 // this will drag ASAN symbols into the binary, even for modules using LOCAL_SANITIZE := never.
37 // So disable sanitization for now. b/38456126
38 sanitize: {
39 never: true,
40 },
Colin Cross1f7f3bd2016-07-27 10:12:38 -070041}
42
43// Create a dummy version of libsigchain which expose the necessary symbols
44// but throws when called. This can be used to get static binaries which don't
45// need the real functionality of the sig chain but need to please the linker.
46cc_library_static {
47 name: "libsigchain_dummy",
48 host_supported: true,
49 defaults: ["art_defaults"],
50 srcs: ["sigchain_dummy.cc"],
51 target: {
52 host: {
53 host_ldlibs: ["-ldl"],
54 },
55 android: {
56 shared_libs: ["liblog"],
57 },
58 },
59}