1// Copyright (C) 2015 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
15cc_defaults {
16    name: "dexdump_defaults",
17    defaults: ["art_defaults"],
18    srcs: [
19        "dexdump_cfg.cc",
20        "dexdump_main.cc",
21        "dexdump.cc",
22    ],
23}
24
25art_cc_binary {
26    name: "dexdump",
27    defaults: ["dexdump_defaults"],
28    host_supported: true,
29    target: {
30        android: {
31            shared_libs: [
32                "libdexfile",
33                "libartbase",
34                "libbase",
35            ],
36        },
37        // Use static libs on host: required for Windows build and
38        // static_sdk_tools build.
39        host: {
40            enabled: true,
41            static_libs: [
42                "libdexfile",
43                "libartbase",
44                "libbase",
45                "libartpalette",
46                "liblog",
47                "libz",
48                "libziparchive",
49            ],
50        },
51        darwin: {
52            enabled: true,
53        },
54    },
55    apex_available: [
56        "com.android.art.release",
57        "com.android.art.debug",
58        "//apex_available:platform", // for SDK
59    ],
60}
61
62art_cc_test {
63    name: "art_dexdump_tests",
64    defaults: [
65        "art_gtest_defaults",
66    ],
67    srcs: ["dexdump_test.cc"],
68    required: ["dexdump"],
69}
70