| 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 | |
| 19 static_library("utility") { | 9 static_library("utility") { |
| 20 sources = [ | 10 sources = [ |
| 21 "chrome_content_utility_client.cc", | 11 "chrome_content_utility_client.cc", |
| 22 "chrome_content_utility_client.h", | 12 "chrome_content_utility_client.h", |
| 23 "chrome_content_utility_ipc_whitelist.cc", | 13 "chrome_content_utility_ipc_whitelist.cc", |
| 24 "chrome_content_utility_ipc_whitelist.h", | 14 "chrome_content_utility_ipc_whitelist.h", |
| 25 "cloud_print/bitmap_image.cc", | 15 "cloud_print/bitmap_image.cc", |
| 26 "cloud_print/bitmap_image.h", | 16 "cloud_print/bitmap_image.h", |
| 27 "cloud_print/pwg_encoder.cc", | 17 "cloud_print/pwg_encoder.cc", |
| 28 "cloud_print/pwg_encoder.h", | 18 "cloud_print/pwg_encoder.h", |
| 29 "image_decoder_impl.cc", | 19 "image_decoder_impl.cc", |
| 30 "image_decoder_impl.h", | 20 "image_decoder_impl.h", |
| 31 "ipc_shell_handler_win.cc", | 21 "ipc_shell_handler_win.cc", |
| 32 "ipc_shell_handler_win.h", | 22 "ipc_shell_handler_win.h", |
| 33 "printing_handler.cc", | 23 "printing_handler.cc", |
| 34 "printing_handler.h", | 24 "printing_handler.h", |
| 35 "shell_handler_impl_win.cc", | 25 "shell_handler_impl_win.cc", |
| 36 "shell_handler_impl_win.h", | 26 "shell_handler_impl_win.h", |
| 37 "utility_message_handler.h", | 27 "utility_message_handler.h", |
| 38 ] | 28 ] |
| 39 | 29 |
| 40 defines = [] | 30 defines = [] |
| 41 configs += [ | 31 configs += [ |
| 42 "//build/config:precompiled_headers", | 32 "//build/config:precompiled_headers", |
| 43 "//build/config/compiler:wexit_time_destructors", | 33 "//build/config/compiler:wexit_time_destructors", |
| 44 ] | 34 ] |
| 45 all_dependent_configs = [ ":utility_ldflags" ] | |
| 46 | 35 |
| 47 public_deps = [] | 36 public_deps = [] |
| 48 deps = [ | 37 deps = [ |
| 49 "//base", | 38 "//base", |
| 50 "//chrome:resources", | 39 "//chrome:resources", |
| 51 "//chrome:strings", | 40 "//chrome:strings", |
| 52 "//chrome/common", | 41 "//chrome/common", |
| 53 "//chrome/common:mojo_bindings", | 42 "//chrome/common:mojo_bindings", |
| 54 "//components/safe_json/utility", | 43 "//components/safe_json/utility", |
| 55 "//components/search_engines", | 44 "//components/search_engines", |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 | 164 |
| 176 if (enable_print_preview || (enable_basic_printing && is_win)) { | 165 if (enable_print_preview || (enable_basic_printing && is_win)) { |
| 177 deps += [ "//pdf" ] | 166 deps += [ "//pdf" ] |
| 178 } else { | 167 } else { |
| 179 sources -= [ | 168 sources -= [ |
| 180 "printing_handler.cc", | 169 "printing_handler.cc", |
| 181 "printing_handler.h", | 170 "printing_handler.h", |
| 182 ] | 171 ] |
| 183 } | 172 } |
| 184 | 173 |
| 185 if (safe_browsing_mode == 1) { | 174 if (is_mac && safe_browsing_mode == 1) { |
| 186 sources += [ | 175 deps += [ "//chrome/utility/safe_browsing/mac" ] |
| 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" ] | |
| 200 } | 176 } |
| 201 } | 177 } |
| 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 |