blob: 5fc338cb58e59a0aca65660660f9690b3431bbee [file] [log] [blame]
Ben Murdoch097c5b22016-05-18 11:27:45 +01001# Copyright 2016 the V8 project authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5{
6 'variables': {
7 'v8_code': 1,
8 },
9 'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
10 'targets': [
11 {
12 'target_name': 'json_fuzzer',
13 'type': 'executable',
14 'dependencies': [
15 'json_fuzzer_lib',
16 ],
17 'include_dirs': [
18 '../..',
19 ],
20 'sources': [
21 'fuzzer.cc',
22 ],
23 },
24 {
25 'target_name': 'json_fuzzer_lib',
26 'type': 'static_library',
27 'dependencies': [
28 'fuzzer_support',
29 ],
30 'include_dirs': [
31 '../..',
32 ],
33 'sources': [ ### gcmole(all) ###
34 'json.cc',
35 ],
36 },
37 {
38 'target_name': 'parser_fuzzer',
39 'type': 'executable',
40 'dependencies': [
41 'parser_fuzzer_lib',
42 ],
43 'include_dirs': [
44 '../..',
45 ],
46 'sources': [
47 'fuzzer.cc',
48 ],
49 },
50 {
51 'target_name': 'parser_fuzzer_lib',
52 'type': 'static_library',
53 'dependencies': [
54 'fuzzer_support',
55 ],
56 'include_dirs': [
57 '../..',
58 ],
59 'sources': [ ### gcmole(all) ###
60 'parser.cc',
61 ],
62 },
63 {
64 'target_name': 'regexp_fuzzer',
65 'type': 'executable',
66 'dependencies': [
67 'regexp_fuzzer_lib',
68 ],
69 'include_dirs': [
70 '../..',
71 ],
72 'sources': [
73 'fuzzer.cc',
74 ],
75 },
76 {
77 'target_name': 'regexp_fuzzer_lib',
78 'type': 'static_library',
79 'dependencies': [
80 'fuzzer_support',
81 ],
82 'include_dirs': [
83 '../..',
84 ],
85 'sources': [ ### gcmole(all) ###
86 'regexp.cc',
87 ],
88 },
89 {
90 'target_name': 'fuzzer_support',
91 'type': 'static_library',
92 'dependencies': [
93 '../../tools/gyp/v8.gyp:v8_libplatform',
94 ],
95 'include_dirs': [
96 '../..',
97 ],
98 'sources': [ ### gcmole(all) ###
99 'fuzzer-support.cc',
100 'fuzzer-support.h',
101 ],
102 'conditions': [
103 ['component=="shared_library"', {
104 # fuzzers can't be built against a shared library, so we need to
105 # depend on the underlying static target in that case.
106 'dependencies': ['../../tools/gyp/v8.gyp:v8_maybe_snapshot'],
107 }, {
108 'dependencies': ['../../tools/gyp/v8.gyp:v8'],
109 }],
110 ],
111 },
112 ],
113 'conditions': [
114 ['test_isolation_mode != "noop"', {
115 'targets': [
116 {
117 'target_name': 'fuzzer_run',
118 'type': 'none',
119 'dependencies': [
120 'json_fuzzer',
121 'parser_fuzzer',
122 'regexp_fuzzer',
123 ],
124 'includes': [
125 '../../build/isolate.gypi',
126 ],
127 'sources': [
128 'fuzzer.isolate',
129 ],
130 },
131 ],
132 }],
133 ],
134}