blob: 5aa159e98b7678572601635a7aea9b37970e4921 [file] [log] [blame]
Colin Crossfe6064a2016-08-30 13:49:26 -07001//
2// Copyright (C) 2012 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
17art_cc_defaults {
18 name: "libart-disassembler-defaults",
19 defaults: ["art_defaults"],
20 host_supported: true,
Colin Crossfe6064a2016-08-30 13:49:26 -070021 srcs: [
22 "disassembler.cc",
Colin Crossfe6064a2016-08-30 13:49:26 -070023 "disassembler_mips.cc",
24 "disassembler_x86.cc",
25 ],
Roland Levillain5725e7c2018-11-06 13:31:48 +000026 codegen: {
27 arm: {
28 srcs: ["disassembler_arm.cc"]
29 },
30 arm64: {
31 srcs: ["disassembler_arm64.cc"]
32 },
33 // TODO: We should also conditionally include the MIPS32/MIPS64 and the
34 // x86/x86-64 disassembler definitions (b/119090273). However, using the
35 // following syntax here:
36 //
37 // mips: {
38 // srcs: ["disassembler_mips.cc"]
39 // },
40 // mips64: {
41 // srcs: ["disassembler_mips.cc"]
42 // },
43 // x86: {
44 // srcs: ["disassembler_x86.cc"]
45 // },
46 // x86_64: {
47 // srcs: ["disassembler_x86.cc"]
48 // },
49 //
50 // does not work, as it generates a file rejected by ninja with this
51 // error message (e.g. on host, where we include all the back ends by
52 // default):
53 //
54 // FAILED: ninja: out/soong/build.ninja:320768: multiple rules generate out/soong/.intermediates/art/disassembler/libart-disassembler/linux_glibc_x86_64_static/obj/art/disassembler/disassembler_mips.o [-w dupbuild=err]
55 },
Andreas Gampe31fcbf82016-09-12 16:22:43 -070056 include_dirs: ["art/runtime"],
Colin Crossfe6064a2016-08-30 13:49:26 -070057
58 shared_libs: [
Colin Crossfe6064a2016-08-30 13:49:26 -070059 "libbase",
60 ],
David Sehr67bf42e2018-02-26 16:43:04 -080061 header_libs: [
62 "art_libartbase_headers",
63 ],
Colin Crossfe6064a2016-08-30 13:49:26 -070064 export_include_dirs: ["."],
65}
66
67art_cc_library {
68 name: "libart-disassembler",
69 defaults: ["libart-disassembler-defaults"],
70 shared_libs: [
Anton Kirilov29b0cde2016-09-06 13:01:03 +010071 // For disassembler_arm*.
Roland Levillain12dd9ae2018-11-06 13:32:06 +000072 "libvixl",
Colin Crossfe6064a2016-08-30 13:49:26 -070073 ],
74}
75
76art_cc_library {
77 name: "libartd-disassembler",
78 defaults: [
Colin Crossfe6064a2016-08-30 13:49:26 -070079 "art_debug_defaults",
Andreas Gampe5115efb2017-05-24 16:55:54 -070080 "libart-disassembler-defaults",
Colin Crossfe6064a2016-08-30 13:49:26 -070081 ],
82 shared_libs: [
Anton Kirilov29b0cde2016-09-06 13:01:03 +010083 // For disassembler_arm*.
Roland Levillain12dd9ae2018-11-06 13:32:06 +000084 "libvixld",
Colin Crossfe6064a2016-08-30 13:49:26 -070085 ],
86}