blob: 32094787473bf45dcf5deceff3613b17a892ee5f [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",
Josh Gaod32d79d2018-02-26 14:29:25 -080019
Colin Cross1f7f3bd2016-07-27 10:12:38 -070020 host_supported: true,
21 defaults: ["art_defaults"],
Colin Cross1f7f3bd2016-07-27 10:12:38 -070022 target: {
Josh Gaod32d79d2018-02-26 14:29:25 -080023 linux: {
24 shared: {
25 srcs: ["sigchain_dummy.cc"],
26 },
27 static: {
28 srcs: ["sigchain.cc"],
29 },
30 },
31
32 darwin: {
33 srcs: ["sigchain_dummy.cc"],
34 },
35
Colin Cross1f7f3bd2016-07-27 10:12:38 -070036 android: {
Josh Gaocca6fc02018-03-12 16:37:21 -070037 whole_static_libs: ["libasync_safe"],
Colin Cross1f7f3bd2016-07-27 10:12:38 -070038 },
39 },
Colin Cross1f7f3bd2016-07-27 10:12:38 -070040}
41
42// Create a dummy version of libsigchain which expose the necessary symbols
43// but throws when called. This can be used to get static binaries which don't
44// need the real functionality of the sig chain but need to please the linker.
45cc_library_static {
46 name: "libsigchain_dummy",
47 host_supported: true,
48 defaults: ["art_defaults"],
49 srcs: ["sigchain_dummy.cc"],
50 target: {
Colin Cross1f7f3bd2016-07-27 10:12:38 -070051 android: {
Josh Gaocca6fc02018-03-12 16:37:21 -070052 whole_static_libs: ["libasync_safe"],
Colin Cross1f7f3bd2016-07-27 10:12:38 -070053 },
54 },
55}
Josh Gao1eac77e2018-02-26 15:54:41 -080056
57art_cc_test {
58 name: "art_sigchain_tests",
59 defaults: [
60 "art_gtest_defaults",
61 ],
62 srcs: ["sigchain_test.cc"],
63 whole_static_libs: ["libsigchain"],
64}
Colin Cross92988752019-03-28 22:40:40 -070065
66filegroup {
67 name: "art_sigchain_version_script32.txt",
68 srcs: ["version-script32.txt"],
69}
70
71filegroup {
72 name: "art_sigchain_version_script64.txt",
73 srcs: ["version-script64.txt"],
74}