OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/symlink.gni") | 5 import("//build/symlink.gni") |
| 6 import("//testing/libfuzzer/fuzzer_test.gni") |
6 import("//testing/test.gni") | 7 import("//testing/test.gni") |
7 | 8 |
8 if (is_android) { | 9 if (is_android) { |
9 import("//build/config/android/rules.gni") | 10 import("//build/config/android/rules.gni") |
10 } | 11 } |
11 | 12 |
12 config("tools_config") { | 13 config("tools_config") { |
13 include_dirs = [ | 14 include_dirs = [ |
14 "src", | 15 "src", |
15 "src/third_party", | 16 "src/third_party", |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 "src/third_party/libdisasm/x86_operand_list.h", | 141 "src/third_party/libdisasm/x86_operand_list.h", |
141 ] | 142 ] |
142 | 143 |
143 defines = [ "BPLOG_MINIMUM_SEVERITY=SEVERITY_ERROR" ] | 144 defines = [ "BPLOG_MINIMUM_SEVERITY=SEVERITY_ERROR" ] |
144 | 145 |
145 configs -= [ "//build/config/compiler:chromium_code" ] | 146 configs -= [ "//build/config/compiler:chromium_code" ] |
146 configs += [ "//build/config/compiler:no_chromium_code" ] | 147 configs += [ "//build/config/compiler:no_chromium_code" ] |
147 configs += [ ":tools_config" ] | 148 configs += [ ":tools_config" ] |
148 } | 149 } |
149 | 150 |
| 151 fuzzer_test("minidump_fuzzer") { |
| 152 sources = [ |
| 153 "minidump_fuzzer.cc", |
| 154 "src/processor/exploitability.cc", |
| 155 "src/processor/minidump.cc", |
| 156 "src/processor/minidump_processor.cc", |
| 157 ] |
| 158 |
| 159 deps = [ |
| 160 ":stackwalk_common", |
| 161 "//base", |
| 162 ] |
| 163 |
| 164 defines = [ "BPLOG_MINIMUM_SEVERITY=SEVERITY_ERROR" ] |
| 165 include_dirs = [ "src" ] |
| 166 dict = "minidump_fuzzer.dict" |
| 167 libfuzzer_options = [ |
| 168 "close_fd_mask=3", |
| 169 "max_len=128000", |
| 170 ] |
| 171 |
| 172 # Always want these files included regardless of platform. |
| 173 set_sources_assignment_filter([]) |
| 174 sources += [ |
| 175 "src/processor/exploitability_linux.cc", |
| 176 "src/processor/exploitability_linux.h", |
| 177 "src/processor/exploitability_win.cc", |
| 178 "src/processor/exploitability_win.h", |
| 179 "src/processor/symbolic_constants_win.cc", |
| 180 "src/processor/symbolic_constants_win.h", |
| 181 ] |
| 182 } |
| 183 |
150 executable("microdump_stackwalk") { | 184 executable("microdump_stackwalk") { |
151 sources = [ | 185 sources = [ |
152 "src/processor/microdump.cc", | 186 "src/processor/microdump.cc", |
153 "src/processor/microdump_processor.cc", | 187 "src/processor/microdump_processor.cc", |
154 "src/processor/microdump_stackwalk.cc", | 188 "src/processor/microdump_stackwalk.cc", |
155 ] | 189 ] |
156 | 190 |
157 deps = [ | 191 deps = [ |
158 ":stackwalk_common", | 192 ":stackwalk_common", |
159 "//build/config/sanitizers:deps", | 193 "//build/config/sanitizers:deps", |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 # Aliases for convenience. | 262 # Aliases for convenience. |
229 binary_symlink("microdump_stackwalk") { | 263 binary_symlink("microdump_stackwalk") { |
230 binary_label = ":$target_name($host_toolchain)" | 264 binary_label = ":$target_name($host_toolchain)" |
231 } | 265 } |
232 binary_symlink("minidump_stackwalk") { | 266 binary_symlink("minidump_stackwalk") { |
233 binary_label = ":$target_name($host_toolchain)" | 267 binary_label = ":$target_name($host_toolchain)" |
234 } | 268 } |
235 binary_symlink("minidump_dump") { | 269 binary_symlink("minidump_dump") { |
236 binary_label = ":$target_name($host_toolchain)" | 270 binary_label = ":$target_name($host_toolchain)" |
237 } | 271 } |
| 272 binary_symlink("minidump_fuzzer") { |
| 273 binary_label = ":$target_name($host_toolchain)" |
| 274 } |
238 } | 275 } |
239 } | 276 } |
240 | 277 |
241 # Mac -------------------------------------------------------------------------- | 278 # Mac -------------------------------------------------------------------------- |
242 | 279 |
243 if (is_mac) { | 280 if (is_mac) { |
244 if (current_toolchain == host_toolchain) { | 281 if (current_toolchain == host_toolchain) { |
245 # TODO(GYP) This should be only 64-bit on Mac. From .gypi: | 282 # TODO(GYP) This should be only 64-bit on Mac. From .gypi: |
246 # Like ld, dump_syms needs to operate on enough data that it may | 283 # Like ld, dump_syms needs to operate on enough data that it may |
247 # actually need to be able to address more than 4GB. Use x86_64. | 284 # actually need to be able to address more than 4GB. Use x86_64. |
(...skipping 659 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
907 | 944 |
908 if (is_android) { | 945 if (is_android) { |
909 # TODO(GYP_GONE) Delete this after we've converted everything to GN. | 946 # TODO(GYP_GONE) Delete this after we've converted everything to GN. |
910 group("breakpad_unittests_deps") { | 947 group("breakpad_unittests_deps") { |
911 testonly = true | 948 testonly = true |
912 deps = [ | 949 deps = [ |
913 ":breakpad_unittests", | 950 ":breakpad_unittests", |
914 ] | 951 ] |
915 } | 952 } |
916 } | 953 } |
OLD | NEW |