| 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/features.gni") | 5 import("//build/config/features.gni") |
| 6 import("//build/config/sysroot.gni") |
| 6 import("//build/config/ui.gni") | 7 import("//build/config/ui.gni") |
| 7 import("//testing/test.gni") | 8 import("//testing/test.gni") |
| 8 if (is_mac) { | 9 if (is_mac) { |
| 9 import("//build/config/mac/mac_sdk.gni") | 10 import("//build/config/mac/mac_sdk.gni") |
| 10 } | 11 } |
| 11 if (is_android) { | 12 if (is_android) { |
| 12 import("//build/config/android/rules.gni") | 13 import("//build/config/android/rules.gni") |
| 13 } | 14 } |
| 14 | 15 |
| 15 component("printing") { | 16 component("printing") { |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 "printing_context_no_system_dialog.cc", | 122 "printing_context_no_system_dialog.cc", |
| 122 "printing_context_no_system_dialog.h", | 123 "printing_context_no_system_dialog.h", |
| 123 ] | 124 ] |
| 124 } | 125 } |
| 125 | 126 |
| 126 if (use_cups) { | 127 if (use_cups) { |
| 127 configs += [ ":cups" ] | 128 configs += [ ":cups" ] |
| 128 | 129 |
| 129 if (is_linux) { | 130 if (is_linux) { |
| 130 cups_version = exec_script("cups_config_helper.py", | 131 cups_version = exec_script("cups_config_helper.py", |
| 131 [ "--api-version" ], | 132 [ |
| 133 "--api-version", |
| 134 sysroot, |
| 135 ], |
| 132 "trim string") | 136 "trim string") |
| 133 | 137 |
| 134 if (cups_version == "1.6" || cups_version == "1.7") { | 138 if (cups_version == "1.6" || cups_version == "1.7") { |
| 135 cflags += [ | 139 cflags += [ |
| 136 # CUPS 1.6 deprecated the PPD APIs, but we will stay with this | 140 # CUPS 1.6 deprecated the PPD APIs, but we will stay with this |
| 137 # API for now as supported Linux and Mac OS'es are still using | 141 # API for now as supported Linux and Mac OS'es are still using |
| 138 # older versions of CUPS. More info: crbug.com/226176 | 142 # older versions of CUPS. More info: crbug.com/226176 |
| 139 "-Wno-deprecated-declarations", | 143 "-Wno-deprecated-declarations", |
| 140 # CUPS 1.7 deprecates httpConnectEncrypt(), see the mac section | 144 # CUPS 1.7 deprecates httpConnectEncrypt(), see the mac section |
| 141 # below. | 145 # below. |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 } | 244 } |
| 241 | 245 |
| 242 if (use_cups) { | 246 if (use_cups) { |
| 243 config("cups") { | 247 config("cups") { |
| 244 defines = [ "USE_CUPS" ] | 248 defines = [ "USE_CUPS" ] |
| 245 | 249 |
| 246 if (is_mac) { | 250 if (is_mac) { |
| 247 libs = [ "cups" ] | 251 libs = [ "cups" ] |
| 248 lib_dirs = [ "$mac_sdk_path/usr/lib" ] | 252 lib_dirs = [ "$mac_sdk_path/usr/lib" ] |
| 249 } else { | 253 } else { |
| 250 libs = exec_script("cups_config_helper.py", [ "--libs-for-gn" ], "value") | 254 libs = exec_script("cups_config_helper.py", |
| 255 [ |
| 256 "--libs-for-gn", |
| 257 sysroot, |
| 258 ], |
| 259 "value") |
| 251 } | 260 } |
| 252 } | 261 } |
| 253 } | 262 } |
| 254 | 263 |
| 255 if (is_android) { | 264 if (is_android) { |
| 256 # GYP: //printing/printing.gyp:printing_jni_headers | 265 # GYP: //printing/printing.gyp:printing_jni_headers |
| 257 generate_jni("printing_jni_headers") { | 266 generate_jni("printing_jni_headers") { |
| 258 sources = [ | 267 sources = [ |
| 259 "android/java/src/org/chromium/printing/PrintingContext.java", | 268 "android/java/src/org/chromium/printing/PrintingContext.java", |
| 260 ] | 269 ] |
| 261 jni_package = "printing" | 270 jni_package = "printing" |
| 262 } | 271 } |
| 263 | 272 |
| 264 # GYP: //printing/printing.gyp:printing_java | 273 # GYP: //printing/printing.gyp:printing_java |
| 265 android_library("printing_java") { | 274 android_library("printing_java") { |
| 266 deps = [ | 275 deps = [ |
| 267 "//base:base_java", | 276 "//base:base_java", |
| 268 ] | 277 ] |
| 269 DEPRECATED_java_in_dir = "android/java/src" | 278 DEPRECATED_java_in_dir = "android/java/src" |
| 270 } | 279 } |
| 271 } | 280 } |
| OLD | NEW |