xref: /aosp_15_r20/external/cronet/testing/libfuzzer/proto/BUILD.gn (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1# Copyright 2017 The Chromium Authors
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5import("//build/config/cronet/config.gni")
6import("//third_party/protobuf/proto_library.gni")
7
8proto_library("json_proto") {
9  proto_in_dir = "//"
10  sources = [ "json.proto" ]
11}
12
13if (!is_cronet_build) {
14  source_set("json_proto_converter") {
15    sources = [
16      "json_proto_converter.cc",
17      "json_proto_converter.h",
18    ]
19    deps = [ ":json_proto" ]
20  }
21
22  static_library("skia_image_filter_converter") {
23    sources = [
24      "skia_image_filter_proto_converter.cc",
25      "skia_image_filter_proto_converter.h",
26    ]
27    deps = [
28      ":skia_image_filter_proto",
29      "//base",
30      "//skia",
31      "//third_party/libprotobuf-mutator",
32    ]
33    defines = [ "AVOID_MISBEHAVIOR=1" ]
34    testonly = true
35
36    #  Can't disable instrumentation because of container-overflow false
37    # positives.
38    # Assertion failures and integer oveflows in skia are uninteresting.
39    if (is_debug || is_ubsan) {
40      all_dependent_configs = [ "//testing/libfuzzer:no_clusterfuzz" ]
41    }
42  }
43
44  source_set("url_proto_converter") {
45    sources = [
46      "url_proto_converter.cc",
47      "url_proto_converter.h",
48    ]
49    deps = [ ":url_proto" ]
50  }
51
52  proto_library("skia_image_filter_proto") {
53    sources = [ "skia_image_filter.proto" ]
54  }
55
56  proto_library("url_proto") {
57    sources = [ "url.proto" ]
58  }
59}
60