| Index: build/common.gypi
|
| diff --git a/build/common.gypi b/build/common.gypi
|
| index 3c4547ce0d2b718ed8c7b8c15b6d56a408910391..7363444fd93800d040bf4232abbfbbcac4b03619 100644
|
| --- a/build/common.gypi
|
| +++ b/build/common.gypi
|
| @@ -2266,6 +2266,15 @@
|
| ['win_use_allocator_shim==0', {
|
| 'defines': ['NO_TCMALLOC'],
|
| }],
|
| + ['os_posix==1 and chromium_code==1', {
|
| + # Non-chromium code is not guaranteed to compile cleanly
|
| + # with _FORTIFY_SOURCE. Also, fortified build may fail
|
| + # when optimizations are disabled, so only do that for Release
|
| + # build.
|
| + 'defines': [
|
| + '_FORTIFY_SOURCE=2',
|
| + ],
|
| + }],
|
| ['OS=="linux" or OS=="android"', {
|
| 'target_conditions': [
|
| ['_toolset=="target"', {
|
| @@ -2312,15 +2321,6 @@
|
| '-Wl,-z,now',
|
| '-Wl,-z,relro',
|
| ],
|
| - 'conditions': [
|
| - ['chromium_code==1', {
|
| - # Non-chromium code is not guaranteed to compile cleanly
|
| - # with _FORTIFY_SOURCE.
|
| - 'defines': [
|
| - '_FORTIFY_SOURCE=2',
|
| - ],
|
| - }],
|
| - ],
|
| },
|
| }],
|
| ['os_posix==1 and OS!="mac" and OS!="ios"', {
|
|
|