| 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/config/crypto.gni") | 5 import("//build/config/crypto.gni") |
| 6 import("//build/config/features.gni") | 6 import("//build/config/features.gni") |
| 7 import("//build/config/sysroot.gni") | 7 import("//build/config/sysroot.gni") |
| 8 | 8 |
| 9 # Provides a way for the utility library to push ldflags to dependents. |
| 10 config("utility_ldflags") { |
| 11 if (is_mac && safe_browsing_mode == 1) { |
| 12 libs = [ |
| 13 "bz2", |
| 14 "CoreFoundation.framework", |
| 15 ] |
| 16 } |
| 17 } |
| 18 |
| 9 static_library("utility") { | 19 static_library("utility") { |
| 10 sources = [ | 20 sources = [ |
| 11 "chrome_content_utility_client.cc", | 21 "chrome_content_utility_client.cc", |
| 12 "chrome_content_utility_client.h", | 22 "chrome_content_utility_client.h", |
| 13 "chrome_content_utility_ipc_whitelist.cc", | 23 "chrome_content_utility_ipc_whitelist.cc", |
| 14 "chrome_content_utility_ipc_whitelist.h", | 24 "chrome_content_utility_ipc_whitelist.h", |
| 15 "cloud_print/bitmap_image.cc", | 25 "cloud_print/bitmap_image.cc", |
| 16 "cloud_print/bitmap_image.h", | 26 "cloud_print/bitmap_image.h", |
| 17 "cloud_print/pwg_encoder.cc", | 27 "cloud_print/pwg_encoder.cc", |
| 18 "cloud_print/pwg_encoder.h", | 28 "cloud_print/pwg_encoder.h", |
| 19 "image_decoder_impl.cc", | 29 "image_decoder_impl.cc", |
| 20 "image_decoder_impl.h", | 30 "image_decoder_impl.h", |
| 21 "ipc_shell_handler_win.cc", | 31 "ipc_shell_handler_win.cc", |
| 22 "ipc_shell_handler_win.h", | 32 "ipc_shell_handler_win.h", |
| 23 "printing_handler.cc", | 33 "printing_handler.cc", |
| 24 "printing_handler.h", | 34 "printing_handler.h", |
| 25 "shell_handler_impl_win.cc", | 35 "shell_handler_impl_win.cc", |
| 26 "shell_handler_impl_win.h", | 36 "shell_handler_impl_win.h", |
| 27 "utility_message_handler.h", | 37 "utility_message_handler.h", |
| 28 ] | 38 ] |
| 29 | 39 |
| 30 defines = [] | 40 defines = [] |
| 31 configs += [ | 41 configs += [ |
| 32 "//build/config:precompiled_headers", | 42 "//build/config:precompiled_headers", |
| 33 "//build/config/compiler:wexit_time_destructors", | 43 "//build/config/compiler:wexit_time_destructors", |
| 34 ] | 44 ] |
| 45 all_dependent_configs = [ ":utility_ldflags" ] |
| 35 | 46 |
| 36 public_deps = [] | 47 public_deps = [] |
| 37 deps = [ | 48 deps = [ |
| 38 "//base", | 49 "//base", |
| 39 "//chrome:resources", | 50 "//chrome:resources", |
| 40 "//chrome:strings", | 51 "//chrome:strings", |
| 41 "//chrome/common", | 52 "//chrome/common", |
| 42 "//chrome/common:mojo_bindings", | 53 "//chrome/common:mojo_bindings", |
| 43 "//components/safe_json/utility", | 54 "//components/safe_json/utility", |
| 44 "//components/search_engines", | 55 "//components/search_engines", |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 | 175 |
| 165 if (enable_print_preview || (enable_basic_printing && is_win)) { | 176 if (enable_print_preview || (enable_basic_printing && is_win)) { |
| 166 deps += [ "//pdf" ] | 177 deps += [ "//pdf" ] |
| 167 } else { | 178 } else { |
| 168 sources -= [ | 179 sources -= [ |
| 169 "printing_handler.cc", | 180 "printing_handler.cc", |
| 170 "printing_handler.h", | 181 "printing_handler.h", |
| 171 ] | 182 ] |
| 172 } | 183 } |
| 173 | 184 |
| 174 if (is_mac && safe_browsing_mode == 1) { | 185 if (safe_browsing_mode == 1) { |
| 175 deps += [ "//chrome/utility/safe_browsing/mac" ] | 186 sources += [ |
| 187 "safe_browsing/mac/convert_big_endian.h", |
| 188 "safe_browsing/mac/dmg_analyzer.cc", |
| 189 "safe_browsing/mac/dmg_analyzer.h", |
| 190 "safe_browsing/mac/dmg_iterator.cc", |
| 191 "safe_browsing/mac/dmg_iterator.h", |
| 192 "safe_browsing/mac/hfs.cc", |
| 193 "safe_browsing/mac/hfs.h", |
| 194 "safe_browsing/mac/read_stream.cc", |
| 195 "safe_browsing/mac/read_stream.h", |
| 196 "safe_browsing/mac/udif.cc", |
| 197 "safe_browsing/mac/udif.h", |
| 198 ] |
| 199 deps += [ "//third_party/zlib" ] |
| 176 } | 200 } |
| 177 } | 201 } |
| 202 |
| 203 if (is_mac) { |
| 204 import("//testing/libfuzzer/fuzzer_test.gni") |
| 205 fuzzer_test("safe_browsing_dmg_fuzzer") { |
| 206 sources = [ |
| 207 "safe_browsing/mac/convert_big_endian.h", |
| 208 "safe_browsing/mac/fuzzer.cc", |
| 209 "safe_browsing/mac/hfs.cc", |
| 210 "safe_browsing/mac/hfs.h", |
| 211 "safe_browsing/mac/read_stream.cc", |
| 212 "safe_browsing/mac/read_stream.h", |
| 213 "safe_browsing/mac/udif.cc", |
| 214 "safe_browsing/mac/udif.h", |
| 215 ] |
| 216 |
| 217 additional_configs = [ ":utility_ldflags" ] |
| 218 |
| 219 deps = [ |
| 220 "//base", |
| 221 "//third_party/zlib", |
| 222 ] |
| 223 } |
| 224 } |
| OLD | NEW |