1package { 2 // See: http://go/android-license-faq 3 // A large-scale-change added 'default_applicable_licenses' to import 4 // all of the 'license_kinds' from "hardware_interfaces_license" 5 // to get the below license kinds: 6 // SPDX-license-identifier-Apache-2.0 7 default_applicable_licenses: ["hardware_interfaces_license"], 8} 9 10cc_defaults { 11 name: "android.hardware.audio-util_default", 12 defaults: ["hidl_defaults"], 13 14 vendor_available: true, 15 16 export_include_dirs: ["include"], 17 18 srcs: [ 19 "CoreUtils.cpp", 20 ], 21 22 shared_libs: [ 23 "liblog", 24 "libutils", 25 "libhidlbase", 26 "android.hardware.audio.common-util", 27 ], 28 export_shared_lib_headers: [ 29 "android.hardware.audio.common-util", 30 ], 31 32 header_libs: [ 33 "libaudio_system_headers", 34 "libhardware_headers", 35 ], 36} 37 38cc_library_shared { 39 name: "android.hardware.audio@2.0-util", 40 defaults: ["android.hardware.audio-util_default"], 41 shared_libs: [ 42 "android.hardware.audio.common@2.0", 43 "android.hardware.audio.common@2.0-util", 44 "android.hardware.audio@2.0", 45 ], 46 cflags: [ 47 "-DMAJOR_VERSION=2", 48 "-DMINOR_VERSION=0", 49 "-include common/all-versions/VersionMacro.h", 50 ], 51} 52 53cc_library_shared { 54 name: "android.hardware.audio@4.0-util", 55 defaults: ["android.hardware.audio-util_default"], 56 shared_libs: [ 57 "android.hardware.audio.common@4.0", 58 "android.hardware.audio.common@4.0-util", 59 "android.hardware.audio@4.0", 60 ], 61 cflags: [ 62 "-DMAJOR_VERSION=4", 63 "-DMINOR_VERSION=0", 64 "-include common/all-versions/VersionMacro.h", 65 ], 66} 67 68cc_library_shared { 69 name: "android.hardware.audio@5.0-util", 70 defaults: ["android.hardware.audio-util_default"], 71 shared_libs: [ 72 "android.hardware.audio.common@5.0", 73 "android.hardware.audio.common@5.0-util", 74 "android.hardware.audio@5.0", 75 ], 76 cflags: [ 77 "-DMAJOR_VERSION=5", 78 "-DMINOR_VERSION=0", 79 "-include common/all-versions/VersionMacro.h", 80 ], 81} 82 83cc_library_shared { 84 name: "android.hardware.audio@6.0-util", 85 defaults: ["android.hardware.audio-util_default"], 86 shared_libs: [ 87 "android.hardware.audio.common@6.0", 88 "android.hardware.audio.common@6.0-util", 89 "android.hardware.audio@6.0", 90 ], 91 cflags: [ 92 "-DMAJOR_VERSION=6", 93 "-DMINOR_VERSION=0", 94 "-include common/all-versions/VersionMacro.h", 95 ], 96} 97 98cc_library { 99 name: "android.hardware.audio@7.0-util", 100 defaults: ["android.hardware.audio-util_default"], 101 shared_libs: [ 102 "android.hardware.audio.common@7.0", 103 "android.hardware.audio.common@7.0-enums", 104 "android.hardware.audio.common@7.0-util", 105 "android.hardware.audio@7.0", 106 "libbase", 107 ], 108 cflags: [ 109 "-DMAJOR_VERSION=7", 110 "-DMINOR_VERSION=0", 111 "-include common/all-versions/VersionMacro.h", 112 ], 113} 114 115cc_library { 116 name: "android.hardware.audio@7.1-util", 117 defaults: ["android.hardware.audio-util_default"], 118 shared_libs: [ 119 "android.hardware.audio.common@7.0", 120 "android.hardware.audio.common@7.1-enums", 121 "android.hardware.audio.common@7.1-util", 122 "android.hardware.audio@7.1", 123 "libbase", 124 ], 125 cflags: [ 126 "-DMAJOR_VERSION=7", 127 "-DMINOR_VERSION=1", 128 "-DCOMMON_TYPES_MINOR_VERSION=0", 129 "-DCORE_TYPES_MINOR_VERSION=0", 130 "-include common/all-versions/VersionMacro.h", 131 ], 132} 133 134// Note: this isn't a VTS test, but rather a unit test 135// to verify correctness of conversion utilities. 136cc_test { 137 name: "android.hardware.audio@7.0-util_tests", 138 defaults: ["android.hardware.audio-util_default"], 139 140 srcs: ["tests/coreutils_tests.cpp"], 141 142 // Use static linking to allow running in presubmit on 143 // targets that don't have HAL V7. 144 static_libs: [ 145 "android.hardware.audio.common@7.0", 146 "android.hardware.audio.common@7.0-enums", 147 "android.hardware.audio.common@7.0-util", 148 "android.hardware.audio@7.0", 149 "android.hardware.audio@7.0-util", 150 ], 151 152 shared_libs: [ 153 "libbase", 154 "libxml2", 155 ], 156 157 cflags: [ 158 "-Werror", 159 "-Wall", 160 "-DMAJOR_VERSION=7", 161 "-DMINOR_VERSION=0", 162 "-include common/all-versions/VersionMacro.h", 163 ], 164 165 test_suites: ["device-tests"], 166} 167 168cc_test { 169 name: "android.hardware.audio@7.1-util_tests", 170 defaults: ["android.hardware.audio-util_default"], 171 172 srcs: ["tests/coreutils_tests.cpp"], 173 174 // Use static linking to allow running in presubmit on 175 // targets that don't have HAL V7.1. 176 static_libs: [ 177 "android.hardware.audio.common@7.0", 178 "android.hardware.audio.common@7.1-enums", 179 "android.hardware.audio.common@7.1-util", 180 "android.hardware.audio@7.1", 181 "android.hardware.audio@7.1-util", 182 ], 183 184 shared_libs: [ 185 "libbase", 186 "libxml2", 187 ], 188 189 cflags: [ 190 "-Werror", 191 "-Wall", 192 "-DMAJOR_VERSION=7", 193 "-DMINOR_VERSION=1", 194 "-DCOMMON_TYPES_MINOR_VERSION=0", 195 "-DCORE_TYPES_MINOR_VERSION=0", 196 "-include common/all-versions/VersionMacro.h", 197 ], 198 199 test_suites: ["device-tests"], 200} 201