Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 1 | // Copyright (C) 2016 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 | |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 15 | art_cc_defaults { |
| 16 | name: "libart-dexlayout-defaults", |
David Sehr | 7639cdc | 2017-04-15 10:06:21 -0700 | [diff] [blame] | 17 | defaults: ["art_defaults"], |
Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 18 | host_supported: true, |
| 19 | srcs: [ |
Mathieu Chartier | f95a75e | 2017-11-03 15:25:52 -0700 | [diff] [blame] | 20 | "compact_dex_writer.cc", |
Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 21 | "dexlayout.cc", |
Jeff Hao | 3ab96b4 | 2016-09-09 18:35:01 -0700 | [diff] [blame] | 22 | "dex_ir.cc", |
Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 23 | "dex_ir_builder.cc", |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 24 | "dex_verify.cc", |
David Sehr | cdcfde7 | 2016-09-26 07:44:04 -0700 | [diff] [blame] | 25 | "dex_visualize.cc", |
Jeff Hao | a862100 | 2016-10-04 18:13:44 +0000 | [diff] [blame] | 26 | "dex_writer.cc", |
Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 27 | ], |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 28 | export_include_dirs: ["."], |
David Sehr | 0225f8e | 2018-01-31 08:52:24 +0000 | [diff] [blame] | 29 | shared_libs: [ |
David Sehr | 0225f8e | 2018-01-31 08:52:24 +0000 | [diff] [blame] | 30 | "libbase", |
| 31 | ], |
Nicolas Geoffray | 65ed42a | 2018-10-30 12:33:04 +0000 | [diff] [blame] | 32 | static_libs: ["libz"], |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 33 | } |
| 34 | |
Andreas Gampe | ec5ed06 | 2018-01-26 16:20:02 -0800 | [diff] [blame] | 35 | cc_defaults { |
| 36 | name: "libart-dexlayout_static_base_defaults", |
| 37 | static_libs: [ |
| 38 | "libbase", |
Nicolas Geoffray | 65ed42a | 2018-10-30 12:33:04 +0000 | [diff] [blame] | 39 | "libz", |
Andreas Gampe | ec5ed06 | 2018-01-26 16:20:02 -0800 | [diff] [blame] | 40 | ], |
| 41 | } |
| 42 | |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 43 | art_cc_library { |
| 44 | name: "libart-dexlayout", |
Pirama Arumuga Nainar | 42d5805 | 2018-04-18 22:59:36 -0700 | [diff] [blame] | 45 | defaults: [ |
| 46 | "libart-dexlayout-defaults", |
| 47 | "dex2oat-pgo-defaults", |
| 48 | ], |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 49 | shared_libs: [ |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 50 | "libdexfile", |
David Sehr | 1f01016 | 2018-05-15 08:59:32 -0700 | [diff] [blame] | 51 | "libartbase", |
David Sehr | 82d046e | 2018-04-23 08:14:19 -0700 | [diff] [blame] | 52 | "libprofile", |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 53 | ], |
Pirama Arumuga Nainar | 02f6ed6 | 2018-01-04 10:52:42 -0800 | [diff] [blame] | 54 | |
Yi Kong | 1d894d9 | 2018-01-19 22:01:14 -0800 | [diff] [blame] | 55 | target: { |
| 56 | android: { |
| 57 | lto: { |
| 58 | thin: true, |
| 59 | }, |
| 60 | }, |
| 61 | }, |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 62 | } |
| 63 | |
Andreas Gampe | ec5ed06 | 2018-01-26 16:20:02 -0800 | [diff] [blame] | 64 | cc_defaults { |
| 65 | name: "libart-dexlayout_static_defaults", |
| 66 | defaults: [ |
| 67 | "libart-dexlayout_static_base_defaults", |
| 68 | "libartbase_static_defaults", |
| 69 | "libdexfile_static_defaults", |
| 70 | "libprofile_static_defaults", |
| 71 | ], |
| 72 | static_libs: ["libart-dexlayout"], |
| 73 | } |
| 74 | |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 75 | art_cc_library { |
| 76 | name: "libartd-dexlayout", |
Mathieu Chartier | 5929beb | 2017-10-20 23:24:10 -0700 | [diff] [blame] | 77 | defaults: [ |
| 78 | "libart-dexlayout-defaults", |
| 79 | "art_debug_defaults", |
| 80 | ], |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 81 | shared_libs: [ |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 82 | "libdexfiled", |
David Sehr | 1f01016 | 2018-05-15 08:59:32 -0700 | [diff] [blame] | 83 | "libartbased", |
David Sehr | 82d046e | 2018-04-23 08:14:19 -0700 | [diff] [blame] | 84 | "libprofiled", |
David Sehr | fcbe15c | 2018-02-15 09:41:13 -0800 | [diff] [blame] | 85 | ], |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 86 | } |
| 87 | |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 88 | cc_defaults { |
Andreas Gampe | ec5ed06 | 2018-01-26 16:20:02 -0800 | [diff] [blame] | 89 | name: "libartd-dexlayout_static_defaults", |
| 90 | defaults: [ |
| 91 | "libart-dexlayout_static_base_defaults", |
| 92 | "libartbased_static_defaults", |
| 93 | "libdexfiled_static_defaults", |
| 94 | "libprofiled_static_defaults", |
| 95 | ], |
| 96 | static_libs: ["libartd-dexlayout"], |
| 97 | } |
| 98 | |
| 99 | cc_defaults { |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 100 | name: "dexlayout-defaults", |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 101 | defaults: ["art_defaults"], |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 102 | host_supported: true, |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 103 | shared_libs: [ |
| 104 | "libbase", |
| 105 | ], |
| 106 | } |
| 107 | |
| 108 | art_cc_binary { |
| 109 | name: "dexlayout", |
| 110 | defaults: ["dexlayout-defaults"], |
David Sehr | 671af6c | 2018-05-17 11:00:35 -0700 | [diff] [blame] | 111 | srcs: ["dexlayout_main.cc"], |
Andreas Gampe | 3fec9ac | 2016-09-13 10:47:28 -0700 | [diff] [blame] | 112 | shared_libs: [ |
David Sehr | 671af6c | 2018-05-17 11:00:35 -0700 | [diff] [blame] | 113 | "libdexfile", |
David Sehr | 82d046e | 2018-04-23 08:14:19 -0700 | [diff] [blame] | 114 | "libprofile", |
David Sehr | 1f01016 | 2018-05-15 08:59:32 -0700 | [diff] [blame] | 115 | "libartbase", |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 116 | "libart-dexlayout", |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 117 | ], |
| 118 | } |
| 119 | |
| 120 | art_cc_binary { |
| 121 | name: "dexlayoutd", |
| 122 | defaults: [ |
| 123 | "art_debug_defaults", |
| 124 | "dexlayout-defaults", |
| 125 | ], |
David Sehr | 671af6c | 2018-05-17 11:00:35 -0700 | [diff] [blame] | 126 | srcs: ["dexlayout_main.cc"], |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 127 | shared_libs: [ |
David Sehr | 671af6c | 2018-05-17 11:00:35 -0700 | [diff] [blame] | 128 | "libdexfiled", |
David Sehr | 82d046e | 2018-04-23 08:14:19 -0700 | [diff] [blame] | 129 | "libprofiled", |
David Sehr | 1f01016 | 2018-05-15 08:59:32 -0700 | [diff] [blame] | 130 | "libartbased", |
Andreas Gampe | 693bfbf | 2017-11-10 12:23:31 -0800 | [diff] [blame] | 131 | "libartd-dexlayout", |
Andreas Gampe | 3fec9ac | 2016-09-13 10:47:28 -0700 | [diff] [blame] | 132 | ], |
Colin Cross | fe6064a | 2016-08-30 13:49:26 -0700 | [diff] [blame] | 133 | } |
Colin Cross | 6e95dd5 | 2016-09-12 15:37:10 -0700 | [diff] [blame] | 134 | |
| 135 | art_cc_test { |
| 136 | name: "art_dexlayout_tests", |
Jeff Hao | ea7c629 | 2016-11-14 18:10:16 -0800 | [diff] [blame] | 137 | defaults: ["art_gtest_defaults"], |
David Sehr | 82d046e | 2018-04-23 08:14:19 -0700 | [diff] [blame] | 138 | shared_libs: [ |
| 139 | "libprofiled", |
| 140 | "libartd-dexlayout", |
| 141 | ], |
Colin Cross | 6e95dd5 | 2016-09-12 15:37:10 -0700 | [diff] [blame] | 142 | srcs: ["dexlayout_test.cc"], |
| 143 | } |
David Sehr | beca4fe | 2017-03-30 17:50:24 -0700 | [diff] [blame] | 144 | |
| 145 | art_cc_binary { |
| 146 | name: "dexdiag", |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 147 | defaults: ["art_defaults"], |
| 148 | host_supported: true, |
David Sehr | beca4fe | 2017-03-30 17:50:24 -0700 | [diff] [blame] | 149 | srcs: ["dexdiag.cc"], |
| 150 | cflags: ["-Wall"], |
| 151 | shared_libs: [ |
| 152 | "libart", |
David Sehr | 671af6c | 2018-05-17 11:00:35 -0700 | [diff] [blame] | 153 | "libdexfile", |
David Sehr | 1f01016 | 2018-05-15 08:59:32 -0700 | [diff] [blame] | 154 | "libartbase", |
David Sehr | beca4fe | 2017-03-30 17:50:24 -0700 | [diff] [blame] | 155 | "libart-dexlayout", |
Andreas Gampe | 281fee0 | 2018-03-05 12:59:30 -0800 | [diff] [blame] | 156 | "libbase", |
David Sehr | beca4fe | 2017-03-30 17:50:24 -0700 | [diff] [blame] | 157 | ], |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 158 | target: { |
| 159 | android: { |
| 160 | shared_libs: [ |
| 161 | "libpagemap", |
Dan Willemsen | 2ca2780 | 2017-09-27 14:57:43 -0700 | [diff] [blame] | 162 | ], |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 163 | }, |
Dan Willemsen | 2ca2780 | 2017-09-27 14:57:43 -0700 | [diff] [blame] | 164 | }, |
David Sehr | beca4fe | 2017-03-30 17:50:24 -0700 | [diff] [blame] | 165 | } |
| 166 | |
David Sehr | 55232f1 | 2017-04-19 14:06:49 -0700 | [diff] [blame] | 167 | art_cc_test { |
| 168 | name: "art_dexdiag_tests", |
| 169 | host_supported: true, |
| 170 | defaults: [ |
| 171 | "art_gtest_defaults", |
| 172 | ], |
| 173 | srcs: ["dexdiag_test.cc"], |
| 174 | } |