1 // 2 // Copyright (C) 2019 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 17 // Build variants {target,host} x {debug,ndebug} x {32,64} 18 cc_defaults { 19 name: "forceredefine-defaults", 20 host_supported: true, 21 srcs: ["forceredefine.cc"], 22 defaults: ["art_defaults"], 23 24 // Note that this tool needs to be built for both 32-bit and 64-bit since it requires 25 // to be same ISA as what it is attached to. 26 compile_multilib: "both", 27 28 shared_libs: [ 29 "libz", 30 "liblog", 31 ], 32 header_libs: [ 33 "libopenjdkjvmti_headers", 34 // Annoyingly you aren't allowed to include even header-only non-ndk libs into an ndk build. 35 // Instead we put the directories this would bring in below in 'include_dirs' 36 // "libnativehelper_header_only", 37 ], 38 include_dirs: [ 39 // NDK headers aren't available in platform NDK builds. 40 "libnativehelper/include_jni", 41 "libnativehelper/header_only_include", 42 ], 43 sdk_version: "current", 44 stl: "libc++_static", 45 target: { 46 android: { 47 static_libs: [ 48 "slicer_ndk_no_rtti", 49 "libbase_ndk", 50 ], 51 }, 52 host: { 53 static_libs: [ 54 "slicer_no_rtti", 55 ], 56 shared_libs: [ 57 "libbase", 58 ], 59 }, 60 }, 61 multilib: { 62 lib32: { 63 suffix: "32", 64 }, 65 lib64: { 66 suffix: "64", 67 }, 68 }, 69 symlink_preferred_arch: true, 70 } 71 72 art_cc_library { 73 name: "libforceredefine", 74 defaults: ["forceredefine-defaults"], 75 } 76 77 art_cc_library { 78 name: "libforceredefined", 79 defaults: [ 80 "art_debug_defaults", 81 "forceredefine-defaults", 82 ], 83 } 84