summaryrefslogtreecommitdiffstats
path: root/printing
diff options
context:
space:
mode:
authorraphael.kubo.da.costa <raphael.kubo.da.costa@intel.com>2015-12-16 12:12:48 -0800
committerCommit bot <commit-bot@chromium.org>2015-12-16 20:14:05 +0000
commit64f5280c212477b92afde98bce74dd79c63b4537 (patch)
tree1f63d2787e9fcae33c148f130229580ef85dc506 /printing
parent581cf3f618e0458bf065b2df90ab5b7f5cb18a8e (diff)
downloadchromium_src-64f5280c212477b92afde98bce74dd79c63b4537.zip
chromium_src-64f5280c212477b92afde98bce74dd79c63b4537.tar.gz
chromium_src-64f5280c212477b92afde98bce74dd79c63b4537.tar.bz2
printing: Invoke cups-config from the sysroot if one is being used.
The gyp version was relying on cups-config in the host when checking the API version, whereas BUILD.gn was not using the sysroot at all. R=sbc@chromium.org,phajdan.jr@chromium.org,thestig@chromium.org BUG=504446 Review URL: https://codereview.chromium.org/1526033002 Cr-Commit-Position: refs/heads/master@{#365600}
Diffstat (limited to 'printing')
-rw-r--r--printing/BUILD.gn13
-rw-r--r--printing/printing.gyp2
2 files changed, 12 insertions, 3 deletions
diff --git a/printing/BUILD.gn b/printing/BUILD.gn
index d8255be..45dfcc8 100644
--- a/printing/BUILD.gn
+++ b/printing/BUILD.gn
@@ -3,6 +3,7 @@
# found in the LICENSE file.
import("//build/config/features.gni")
+import("//build/config/sysroot.gni")
import("//build/config/ui.gni")
import("//testing/test.gni")
if (is_mac) {
@@ -128,7 +129,10 @@ component("printing") {
if (is_linux) {
cups_version = exec_script("cups_config_helper.py",
- [ "--api-version" ],
+ [
+ "--api-version",
+ sysroot,
+ ],
"trim string")
if (cups_version == "1.6" || cups_version == "1.7") {
@@ -247,7 +251,12 @@ if (use_cups) {
libs = [ "cups" ]
lib_dirs = [ "$mac_sdk_path/usr/lib" ]
} else {
- libs = exec_script("cups_config_helper.py", [ "--libs-for-gn" ], "value")
+ libs = exec_script("cups_config_helper.py",
+ [
+ "--libs-for-gn",
+ sysroot,
+ ],
+ "value")
}
}
}
diff --git a/printing/printing.gyp b/printing/printing.gyp
index e2c2883..d1ca4b9 100644
--- a/printing/printing.gyp
+++ b/printing/printing.gyp
@@ -139,7 +139,7 @@
'cups',
],
'variables': {
- 'cups_version': '<!(cups-config --api-version)',
+ 'cups_version': '<!(python cups_config_helper.py --api-version <(sysroot))',
},
'conditions': [
['cups_version in ["1.6", "1.7"]', {