1/* 2 * Copyright (C) 2018 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 17package { 18 default_applicable_licenses: ["Android-Apache-2.0"], 19} 20 21cc_library_static { 22 name: "libpixelusb", 23 vendor: true, 24 export_include_dirs: [ 25 "hidl/include", 26 "include", 27 ], 28 29 srcs: [ 30 "hidl/UsbGadgetUtils.cpp", 31 "UsbOverheatEvent.cpp", 32 "CommonUtils.cpp", 33 "MonitorFfs.cpp", 34 "I2cHelper.cpp", 35 ], 36 37 cflags: [ 38 "-Wall", 39 "-Werror", 40 ], 41 42 shared_libs: [ 43 "libbase", 44 "libbinder", 45 "libcutils", 46 "libhidlbase", 47 "libutils", 48 "libbinder_ndk", 49 "pixelatoms-cpp", 50 "[email protected]", 51 "[email protected]", 52 "[email protected]", 53 "android.hardware.thermal-V1-ndk", 54 ], 55 56 export_shared_lib_headers: [ 57 "pixelatoms-cpp", 58 ], 59 60 static_libs: [ 61 "libthermalutils", 62 ], 63} 64 65cc_library_static { 66 name: "libpixelusb-aidl", 67 vendor: true, 68 export_include_dirs: [ 69 "aidl/include", 70 "include", 71 ], 72 73 srcs: [ 74 "aidl/UsbGadgetAidlUtils.cpp", 75 "UsbOverheatEvent.cpp", 76 "CommonUtils.cpp", 77 "MonitorFfs.cpp", 78 "I2cHelper.cpp", 79 "UsbBusHelper.cpp", 80 ], 81 82 cflags: [ 83 "-Wall", 84 "-Werror", 85 ], 86 87 shared_libs: [ 88 "libbase", 89 "libbinder", 90 "libcutils", 91 "libutils", 92 "pixelatoms-cpp", 93 "android.hardware.usb.gadget-V1-ndk", 94 "[email protected]", 95 "[email protected]", 96 "android.hardware.thermal-V1-ndk", 97 ], 98 99 export_shared_lib_headers: [ 100 "pixelatoms-cpp", 101 ], 102 103 static_libs: [ 104 "libthermalutils", 105 ], 106} 107 108cc_library_static { 109 name: "libpixelusb-usbdp", 110 vendor: true, 111 112 srcs: [ 113 "UsbDpUtils.cpp", 114 ], 115 116 cflags: [ 117 "-Wall", 118 "-Werror", 119 ], 120 121 shared_libs: [ 122 "libbase", 123 "libcutils", 124 "libutils", 125 "android.hardware.usb-V3-ndk", 126 ], 127} 128 129cc_fuzz { 130 name: "libpixelusb_gadgetutils_fuzzer", 131 vendor: true, 132 133 srcs: [ 134 "UsbGadgetUtils_fuzz.cpp", 135 ], 136 137 shared_libs: [ 138 "[email protected]", 139 "libbase", 140 ], 141 142 static_libs: [ 143 "libpixelusb", 144 ], 145 146 fuzz_config: { 147 cc: [ 148 "[email protected]", 149 "[email protected]", 150 ], 151 componentid: 175220, 152 }, 153} 154