Alec Mouri | b2089a3 | 2022-01-15 00:34:20 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2021 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 | */ |
| 17 | |
| 18 | cc_defaults { |
| 19 | name: "surfaceflinger_fuzz_defaults", |
| 20 | include_dirs: [ |
| 21 | "frameworks/native/services/surfaceflinger/tests/unittests", |
| 22 | ], |
| 23 | static_libs: [ |
| 24 | "android.hardware.graphics.composer@2.1-resources", |
| 25 | "libgmock", |
| 26 | "libgui_mocks", |
| 27 | "libgmock_ndk", |
| 28 | "libgmock_main", |
| 29 | "libgtest_ndk_c++", |
| 30 | "libgmock_main_ndk", |
| 31 | "librenderengine_mocks", |
| 32 | "perfetto_trace_protos", |
| 33 | "libcompositionengine_mocks", |
| 34 | "perfetto_trace_protos", |
| 35 | ], |
| 36 | shared_libs: [ |
| 37 | "libprotoutil", |
| 38 | "libstatssocket", |
| 39 | "libstatspull", |
| 40 | "libtimestats", |
| 41 | "libtimestats_proto", |
| 42 | "libprotobuf-cpp-full", |
| 43 | "android.hardware.graphics.mapper@2.0", |
| 44 | "android.hardware.graphics.mapper@3.0", |
| 45 | "android.hardware.graphics.mapper@4.0", |
| 46 | ], |
| 47 | srcs: [ |
| 48 | ":libsurfaceflinger_sources", |
| 49 | ":libsurfaceflinger_mock_sources", |
| 50 | ], |
| 51 | defaults: [ |
| 52 | "libsurfaceflinger_defaults", |
| 53 | ], |
| 54 | header_libs: [ |
| 55 | "libui_fuzzableDataspaces_headers", |
| 56 | "libsurfaceflinger_headers", |
| 57 | "libui_headers", |
| 58 | ], |
| 59 | cflags: [ |
| 60 | "-Wno-unused-result", |
| 61 | "-Wno-conversion", |
| 62 | "-Wno-sign-compare", |
| 63 | ], |
| 64 | fuzz_config: { |
| 65 | cc: [ |
| 66 | "android-media-fuzzing-reports@google.com", |
| 67 | ], |
| 68 | componentid: 155276, |
| 69 | }, |
| 70 | } |
| 71 | |
| 72 | cc_fuzz { |
| 73 | name: "surfaceflinger_fuzzer", |
| 74 | defaults: [ |
| 75 | "surfaceflinger_fuzz_defaults", |
| 76 | ], |
| 77 | srcs: [ |
| 78 | "surfaceflinger_fuzzer.cpp", |
| 79 | ], |
| 80 | } |