diff options
author | zforman <zforman@google.com> | 2016-01-19 21:19:20 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-01-20 05:20:27 +0000 |
commit | fdca0741b22a4dddbf1808b8d0081651662b22c5 (patch) | |
tree | eaa397008e14711556d3bece387a59edb45d3424 /printing | |
parent | 40f30385a7fd945d11c2043eeaae8ef8b3f3337b (diff) | |
download | chromium_src-fdca0741b22a4dddbf1808b8d0081651662b22c5.zip chromium_src-fdca0741b22a4dddbf1808b8d0081651662b22c5.tar.gz chromium_src-fdca0741b22a4dddbf1808b8d0081651662b22c5.tar.bz2 |
clang: Makes builds with clang less dependent on absolute file path
[Note: Dependency claims are only valid on Linux builds]
This change removes absolute file paths from several locations in
produced binaries, reducing the total number of files containing
absolute file paths from ~30k to ~4k.
Specifically, this removes absolute paths from:
.rodata (sysroot based)
.debug_str, .debug_info (debug prefix based)
.debug_line (debug prefix and sysroot based)
.debug_info still contains (on Linux) 22 absolute paths, but
as discussed below, this is most likely simple to resolve.
This can be measured by using
$ find out/Default/ -type f | grep -v ninja | xargs -I '{}' grep -l \
'absolute-path-component' '{}' | wc -l
Before: 30420
After: 3917 (https://gist.github.com/anonymous/fd870076c990fcf792c7)
The remaining instances mostly originate from NaCL not
having the flag enabled. Enabling requires updating the
toolchain's version of clang to newer than release 3.8
Generated ninja files still have some absolute file paths. At
the very least, they contain -fdebug-prefix-map=/ABSOLUTE/PATH/TO/DIR.
This will be removed later.
BUG=439949
Review URL: https://codereview.chromium.org/1556923002
Cr-Commit-Position: refs/heads/master@{#370320}
Diffstat (limited to 'printing')
-rw-r--r-- | printing/BUILD.gn | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/printing/BUILD.gn b/printing/BUILD.gn index 45dfcc8..3b05be4 100644 --- a/printing/BUILD.gn +++ b/printing/BUILD.gn @@ -131,7 +131,7 @@ component("printing") { cups_version = exec_script("cups_config_helper.py", [ "--api-version", - sysroot, + rebase_path(sysroot), ], "trim string") @@ -254,7 +254,7 @@ if (use_cups) { libs = exec_script("cups_config_helper.py", [ "--libs-for-gn", - sysroot, + rebase_path(sysroot), ], "value") } |