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 15package { 16 default_team: "trendy_team_android_kernel", 17 // See: http://go/android-license-faq 18 // A large-scale-change added 'default_applicable_licenses' to import 19 // all of the 'license_kinds' from "system_libufdt_license" 20 // to get the below license kinds: 21 // SPDX-license-identifier-Apache-2.0 22 default_applicable_licenses: ["system_libufdt_license"], 23} 24 25libufdt_tests_cflags = [ 26 "-Wall", 27 "-Werror", 28 "-Wno-error=format", 29] 30 31cc_binary_host { 32 name: "ufdt_gen_test_dts", 33 cflags: libufdt_tests_cflags, 34 srcs: ["ufdt_gen_test_dts.c"], 35} 36 37cc_binary { 38 name: "ufdt_apply_overlay", 39 host_supported: true, 40 cflags: libufdt_tests_cflags, 41 srcs: [ 42 "ufdt_overlay_test_app.c", 43 "util.c", 44 ], 45 static_libs: [ 46 "libufdt", 47 "libfdt", 48 "libufdt_sysdeps", 49 ], 50 required: ["dtc"], 51 target: { 52 host: { 53 stl: "none", 54 dist: { 55 targets: ["dist_files"], 56 dir: "libufdt", 57 }, 58 }, 59 }, 60} 61 62cc_binary_host { 63 name: "extract_dtb", 64 cflags: libufdt_tests_cflags, 65 srcs: [ 66 "extract_dtb.c", 67 "util.c", 68 ], 69 static_libs: [ 70 "libfdt", 71 "libufdt_sysdeps", 72 ], 73 required: ["dtc"], 74 stl: "none", 75 dist: { 76 targets: ["dist_files"], 77 dir: "libufdt", 78 }, 79} 80 81cc_binary { 82 name: "fdt_apply_overlay", 83 host_supported: true, 84 cflags: libufdt_tests_cflags, 85 srcs: [ 86 "fdt_overlay_test_app.c", 87 "util.c", 88 ], 89 static_libs: [ 90 "libfdt", 91 "libufdt_sysdeps", 92 ], 93 required: ["dtc"], 94 target: { 95 host: { 96 stl: "none", 97 dist: { 98 targets: ["dist_files"], 99 dir: "libufdt", 100 }, 101 }, 102 }, 103} 104 105cc_binary_host { 106 name: "ufdt_verify_overlay_host", 107 cflags: libufdt_tests_cflags, 108 srcs: ["ufdt_verify_overlay_app.cpp"], 109 static_libs: [ 110 "libufdt", 111 "libfdt", 112 "libufdt_sysdeps", 113 "libufdt_verify", 114 ], 115 required: ["dtc"], 116 117} 118 119cc_test { 120 name: "ufdt_verify_overlay", 121 cflags: libufdt_tests_cflags, 122 srcs: ["ufdt_verify_overlay_app.cpp"], 123 static_libs: [ 124 "libufdt", 125 "libfdt", 126 "libufdt_sysdeps", 127 "libufdt_verify", 128 ], 129 required: ["dtc"], 130 test_suites: ["vts"], 131 auto_gen_config: false, 132} 133