diff options
| author | sbc <sbc@chromium.org> | 2016-01-27 13:36:26 -0800 |
|---|---|---|
| committer | Commit bot <commit-bot@chromium.org> | 2016-01-27 21:37:28 +0000 |
| commit | d4566597ab32adc5586831308625c0de954e4920 (patch) | |
| tree | 7133afbc9495453a4607aec6f2f30a34dc5709f3 /build | |
| parent | 7eb752802da6d2df624f67855e5bb405a896b4b2 (diff) | |
| download | chromium_src-d4566597ab32adc5586831308625c0de954e4920.zip chromium_src-d4566597ab32adc5586831308625c0de954e4920.tar.gz chromium_src-d4566597ab32adc5586831308625c0de954e4920.tar.bz2 | |
GN: Only honour system_libdir for target toolchain
Without this change when system_libdir is set (e.g.
to lib64) it would apply this to all toolchains
including the host toolchain.
Review URL: https://codereview.chromium.org/1583093002
Cr-Commit-Position: refs/heads/master@{#371875}
Diffstat (limited to 'build')
| -rw-r--r-- | build/config/linux/pkg_config.gni | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/build/config/linux/pkg_config.gni b/build/config/linux/pkg_config.gni index 58769e2..204cbab 100644 --- a/build/config/linux/pkg_config.gni +++ b/build/config/linux/pkg_config.gni @@ -55,20 +55,24 @@ if (sysroot != "") { sysroot, "-a", current_cpu, - "--system_libdir", - system_libdir, ] } else if (pkg_config != "") { pkg_config_args = [ "-p", pkg_config, - "--system_libdir", - system_libdir, ] } else { pkg_config_args = [] } +# Only use the custom libdir when building with the default toolchain. +if (current_toolchain == default_toolchain) { + pkg_config_args += [ + "--system_libdir", + system_libdir, + ] +} + template("pkg_config") { assert(defined(invoker.packages), "Variable |packages| must be defined to be a list in pkg_config.") |
