From f2fcf4df7b83cba250b64877116038eb0d285c0a Mon Sep 17 00:00:00 2001 From: "piman@chromium.org" Date: Fri, 3 Jun 2011 20:05:46 +0000 Subject: Only pass -Wl,--icf=safe to the target compiler, not the host one. BUG=none TEST=run gyp, check -Wl,--icf=safe is added to *.target.mk but not to *.host.mk Review URL: http://codereview.chromium.org/7065051 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87840 0039d316-1c4b-4281-b951-d872f2087c98 --- build/common.gypi | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'build') diff --git a/build/common.gypi b/build/common.gypi index 6664afd..6083fab 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -1183,8 +1183,12 @@ # is then provided to us by gyp. (Currently only gold supports # an --icf flag.) ['LINKER_SUPPORTS_ICF==1 and release_valgrind_build==0', { - 'ldflags': [ - '-Wl,--icf=safe', + 'target_conditions': [ + ['_toolset=="target"', { + 'ldflags': [ + '-Wl,--icf=safe', + ] + }] ] }], ] -- cgit v1.1