1/* 2 * Copyright 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_library_headers { 18 name: "libneuralnetworks_headers", 19 host_supported: false, 20 vendor_available: true, 21 export_include_dirs: ["include"], 22} 23 24cc_library_headers { 25 name: "libneuralnetworks_private_headers", 26 host_supported: false, 27 export_include_dirs: ["."], 28} 29 30cc_library { 31 name: "libneuralnetworks", 32 defaults: ["neuralnetworks_defaults"], 33 use_version_lib: true, 34 host_supported: false, 35 // b/109953668, disable OpenMP 36 // openmp: true, 37 38 srcs: [ 39 "BurstBuilder.cpp", 40 "Callbacks.cpp", 41 "CompilationBuilder.cpp", 42 "ExecutionBuilder.cpp", 43 "ExecutionPlan.cpp", 44 "Manager.cpp", 45 "Memory.cpp", 46 "ModelBuilder.cpp", 47 "NeuralNetworks.cpp", 48 "TypeManager.cpp", 49 "VersionedInterfaces.cpp", 50 ], 51 52 target: { 53 android: { 54 version_script: "libneuralnetworks.map.txt", 55 shared_libs: [ 56 "libbase", 57 "libbinder", 58 "libcutils", 59 "libhidlbase", 60 "libhidltransport", 61 "libhidlmemory", 62 "liblog", 63 "libnativewindow", 64 "libui", 65 "libutils", 66 "android.hardware.neuralnetworks@1.0", 67 "android.hardware.neuralnetworks@1.1", 68 "android.hardware.neuralnetworks@1.2", 69 "android.hidl.allocator@1.0", 70 "android.hidl.memory@1.0", 71 ], 72 static_libs: [ 73 "libcrypto_static", 74 ], 75 }, 76 host: { 77 shared_libs: [ 78 ], 79 }, 80 }, 81 82 static_libs: [ 83 "libneuralnetworks_common", 84 ], 85 86 whole_static_libs: [ 87 "libprocpartition", 88 ], 89 90 shared_libs: [ 91 "libfmq", 92 "libtextclassifier_hash" 93 ], 94 95 header_libs: [ 96 "libneuralnetworks_headers", 97 ], 98 99 export_header_lib_headers: [ 100 "libneuralnetworks_headers", 101 ], 102} 103 104ndk_headers { 105 name: "libneuralnetworks_ndk_headers", 106 from: "include", 107 to: "android", 108 srcs: ["include/NeuralNetworks.h"], 109 license: "NOTICE", 110} 111 112ndk_library { 113 name: "libneuralnetworks", 114 symbol_file: "libneuralnetworks.map.txt", 115 // Android O-MR1 116 first_version: "27", 117} 118 119llndk_library { 120 name: "libneuralnetworks", 121 symbol_file: "libneuralnetworks.map.txt", 122 export_include_dirs: ["include"], 123} 124