1// 2// Copyright (C) 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_defaults { 18 name: "neuralnetworks_vts_functional_defaults", 19 defaults: ["VtsHalTargetTestDefaults"], 20 arch: { 21 x86: { 22 cflags: [ "-D_Float16=__fp16", 23 "-Xclang", "-fnative-half-type", 24 "-Xclang", "-fallow-half-arguments-and-returns" ], 25 }, 26 x86_64: { 27 cflags: [ "-D_Float16=__fp16", 28 "-Xclang", "-fnative-half-type", 29 "-Xclang", "-fallow-half-arguments-and-returns" ], 30 }, 31 }, 32} 33 34cc_library_static { 35 name: "VtsHalNeuralNetworksV1_0_utils", 36 srcs: [ 37 "Callbacks.cpp", 38 "Utils.cpp", 39 ], 40 defaults: ["neuralnetworks_vts_functional_defaults"], 41 export_include_dirs: ["include"], 42 shared_libs: [ 43 "libfmq", 44 "libnativewindow", 45 ], 46 static_libs: [ 47 "android.hardware.neuralnetworks@1.0", 48 "android.hidl.allocator@1.0", 49 "android.hidl.memory@1.0", 50 "libgmock", 51 "libhidlmemory", 52 "libneuralnetworks_generated_test_harness", 53 "libneuralnetworks_utils", 54 ], 55 header_libs: [ 56 "libneuralnetworks_headers", 57 ], 58} 59 60cc_test { 61 name: "VtsHalNeuralnetworksV1_0TargetTest", 62 defaults: ["neuralnetworks_vts_functional_defaults"], 63 srcs: [ 64 "BasicTests.cpp", 65 "GeneratedTestHarness.cpp", 66 "TestAssertions.cpp", 67 "TestMain.cpp", 68 "ValidateModel.cpp", 69 "ValidateRequest.cpp", 70 "VtsHalNeuralnetworks.cpp", 71 ], 72 shared_libs: [ 73 "libfmq", 74 "libnativewindow", 75 ], 76 static_libs: [ 77 "android.hardware.neuralnetworks@1.0", 78 "android.hidl.allocator@1.0", 79 "android.hidl.memory@1.0", 80 "libgmock", 81 "libhidlmemory", 82 "libneuralnetworks_generated_test_harness", 83 "libneuralnetworks_utils", 84 "VtsHalNeuralNetworksV1_0_utils", 85 ], 86 whole_static_libs: [ 87 "neuralnetworks_generated_V1_0_example", 88 ], 89 header_libs: [ 90 "libneuralnetworks_headers", 91 ], 92 test_suites: ["general-tests", "vts"], 93} 94