blob: cf6abfde061f0cf525aedbc6270bb7b04c3f6866 [file] [log] [blame]
Christopher Ferris9323b722017-03-03 17:43:14 -08001//
2// Copyright (C) 2017 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_defaults {
18 name: "libdemangle_defaults",
19
20 host_supported: true,
21
22 cflags: [
23 "-Wall",
24 "-Werror",
25 "-Wextra",
26 ],
Dan Willemsen0f048672017-09-19 17:53:12 -070027
28 target: {
29 linux_bionic: {
30 enabled: true,
31 },
32 },
Christopher Ferris9323b722017-03-03 17:43:14 -080033}
34
35cc_library {
36 name: "libdemangle",
37 defaults: ["libdemangle_defaults"],
Jiyong Park89444322017-06-14 18:58:22 +090038 vendor_available: true,
Christopher Ferris9323b722017-03-03 17:43:14 -080039
40 srcs: [
41 "Demangler.cpp",
42 ],
43
44 local_include_dirs: [
Elliott Hughesdc699a22018-02-16 17:58:14 -080045 "include",
Christopher Ferris9323b722017-03-03 17:43:14 -080046 ],
47
48 export_include_dirs: [
Elliott Hughesdc699a22018-02-16 17:58:14 -080049 "include",
Christopher Ferris9323b722017-03-03 17:43:14 -080050 ],
51}
52
Christopher Ferrisa11dc8f2017-03-13 15:54:55 -070053cc_binary {
54 name: "demangle",
55 defaults: ["libdemangle_defaults"],
56 srcs: ["demangle.cpp"],
57 host_supported: true,
58
59 shared_libs: ["libdemangle"],
60}
61
Christopher Ferris9323b722017-03-03 17:43:14 -080062//-------------------------------------------------------------------------
63// Unit Tests
64//-------------------------------------------------------------------------
65cc_test {
66 name: "libdemangle_test",
67 defaults: ["libdemangle_defaults"],
68
69 srcs: [
70 "DemangleTest.cpp",
71 ],
72
73 cflags: [
74 "-O0",
75 "-g",
76 ],
77
78 shared_libs: [
79 "libdemangle",
80 ],
Elliott Hughes40fdf3f2018-04-27 16:12:06 -070081
82 test_suites: ["device-tests"],
Elliott Hughes03d183a2018-05-03 10:06:45 -070083 required: [
84 "libdemangle",
85 ],
Christopher Ferris9323b722017-03-03 17:43:14 -080086}