diff options
author | Dan Willemsen <dwillemsen@google.com> | 2016-03-29 17:31:57 -0700 |
---|---|---|
committer | Dan Willemsen <dwillemsen@google.com> | 2016-03-29 18:03:54 -0700 |
commit | 0c38c5ea1719bcb502ae5d15eed1bd90f6b1d3cd (patch) | |
tree | 47591634278821cd707917f0e4f9238a1e490e04 /cc | |
parent | 7b106e4e9fb13e39ac9a1613a7ddeac3fef2d4b1 (diff) | |
download | build_soong-0c38c5ea1719bcb502ae5d15eed1bd90f6b1d3cd.tar.gz build_soong-0c38c5ea1719bcb502ae5d15eed1bd90f6b1d3cd.tar.bz2 build_soong-0c38c5ea1719bcb502ae5d15eed1bd90f6b1d3cd.zip |
Only add -fdebug-prefix-map on Linux hosts
Change-Id: I4fb865fbe40020f2d69d598491e755f793b62b7c
Diffstat (limited to 'cc')
-rw-r--r-- | cc/cc.go | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -79,7 +79,6 @@ var ( "-Wno-unused", "-Winit-self", "-Wpointer-arith", - "-fdebug-prefix-map=/proc/self/cwd=", // COMMON_RELEASE_CFLAGS "-DNDEBUG", @@ -114,6 +113,10 @@ var ( ) func init() { + if common.CurrentHostType() == common.Linux { + commonGlobalCflags = append(commonGlobalCflags, "-fdebug-prefix-map=/proc/self/cwd=") + } + pctx.StaticVariable("commonGlobalCflags", strings.Join(commonGlobalCflags, " ")) pctx.StaticVariable("deviceGlobalCflags", strings.Join(deviceGlobalCflags, " ")) pctx.StaticVariable("hostGlobalCflags", strings.Join(hostGlobalCflags, " ")) |