Steven Moreland | 88b1d3c | 2019-10-14 17:19:28 -0700 | [diff] [blame] | 1 | cc_fuzz { |
| 2 | name: "binder_parcel_fuzzer", |
Steven Moreland | 28f8142 | 2019-10-03 10:40:59 -0700 | [diff] [blame] | 3 | defaults: ["libbinder_ndk_host_user"], |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 4 | host_supported: true, |
Steven Moreland | 97d4e1a | 2019-10-29 14:24:26 -0700 | [diff] [blame] | 5 | |
| 6 | fuzz_config: { |
| 7 | cc: ["smoreland@google.com"], |
| 8 | }, |
| 9 | |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 10 | srcs: [ |
| 11 | "binder.cpp", |
Steven Moreland | 28f8142 | 2019-10-03 10:40:59 -0700 | [diff] [blame] | 12 | "binder_ndk.cpp", |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 13 | "hwbinder.cpp", |
| 14 | "main.cpp", |
Steven Moreland | 5e561af | 2020-10-08 02:16:03 +0000 | [diff] [blame] | 15 | "random_fd.cpp", |
| 16 | "random_parcel.cpp", |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 17 | "util.cpp", |
| 18 | ], |
| 19 | static_libs: [ |
| 20 | "libbase", |
Steven Moreland | 362e4da | 2020-10-16 19:49:39 +0000 | [diff] [blame] | 21 | "libbinder_random_parcel", |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 22 | "libcgrouprc", |
| 23 | "libcgrouprc_format", |
| 24 | "libcutils", |
| 25 | "libhidlbase", |
| 26 | "liblog", |
| 27 | "libprocessgroup", |
| 28 | "libjsoncpp", |
| 29 | "libutils", |
| 30 | ], |
| 31 | |
| 32 | target: { |
| 33 | android: { |
Steven Moreland | 28f8142 | 2019-10-03 10:40:59 -0700 | [diff] [blame] | 34 | shared_libs: [ |
| 35 | "libbinder_ndk", |
| 36 | "libbinder", |
| 37 | ], |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 38 | }, |
| 39 | host: { |
Steven Moreland | 28f8142 | 2019-10-03 10:40:59 -0700 | [diff] [blame] | 40 | static_libs: [ |
| 41 | "libbinder_ndk", |
| 42 | "libbinder", |
| 43 | ], |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 44 | }, |
| 45 | }, |
Steven Moreland | 88b1d3c | 2019-10-14 17:19:28 -0700 | [diff] [blame] | 46 | // This flag enables verbose output in the fuzz target, and is very useful |
| 47 | // for debugging a failure. If you are trying to diagnose how a crash was |
| 48 | // produced, you may find uncommenting the below line very useful. |
| 49 | // cflags: ["-DENABLE_LOG_FUZZ"], |
Steven Moreland | 46e0da7 | 2019-09-05 15:52:02 -0700 | [diff] [blame] | 50 | } |
Steven Moreland | 362e4da | 2020-10-16 19:49:39 +0000 | [diff] [blame] | 51 | |
| 52 | cc_library_static { |
| 53 | name: "libbinder_random_parcel", |
| 54 | host_supported: true, |
Yifan Hong | f856a98 | 2020-10-30 14:51:17 -0700 | [diff] [blame] | 55 | target: { |
| 56 | darwin: { |
| 57 | enabled: false, |
| 58 | } |
| 59 | }, |
Steven Moreland | 362e4da | 2020-10-16 19:49:39 +0000 | [diff] [blame] | 60 | srcs: [ |
| 61 | "random_fd.cpp", |
| 62 | "random_parcel.cpp", |
| 63 | ], |
| 64 | shared_libs: [ |
| 65 | "libbase", |
| 66 | "libbinder", |
| 67 | "libcutils", |
| 68 | "libutils", |
| 69 | ], |
| 70 | local_include_dirs: ["include_random_parcel"], |
| 71 | export_include_dirs: ["include_random_parcel"], |
| 72 | } |