From 3af9382a5dde5de9260b31a6c6912f352638b60e Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Mon, 9 May 2016 13:47:09 +0200 Subject: [PATCH] build: don't compile with -B, redux It looks like suppressing `-B` and `-fuse-ld=gold` from common.gypi is not very reliable. I'm positive it worked when commit 3cdb506 ("build: don't compile with -B") was merged but subsequent updates appear to have broken it again. Take the nuclear option and disable them from `tools/node_gyp.py`. Fixes: https://github.com/nodejs/node/issues/6603 PR-URL: https://github.com/nodejs/node/pull/6650 Refs: https://github.com/nodejs/node/pull/6393 Reviewed-By: Anna Henningsen --- common.gypi | 3 --- tools/gyp_node.py | 7 +++++++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/common.gypi b/common.gypi index 10da7abccc447c..8da603d00f618e 100644 --- a/common.gypi +++ b/common.gypi @@ -25,9 +25,6 @@ # Don't bake anything extra into the snapshot. 'v8_use_external_startup_data%': 0, - # Don't compile with -B, we don't bundle ld.gold. - 'linux_use_bundled_gold%': 0, - 'conditions': [ ['OS == "win"', { 'os_posix': 0, diff --git a/tools/gyp_node.py b/tools/gyp_node.py index 0ceb93341f12d3..8de046aae259f1 100755 --- a/tools/gyp_node.py +++ b/tools/gyp_node.py @@ -56,5 +56,12 @@ def run_gyp(args): args.append('-Dcomponent=static_library') args.append('-Dlibrary=static_library') + + # Don't compile with -B and -fuse-ld=, we don't bundle ld.gold. Can't be + # set in common.gypi due to how deps/v8/build/toolchain.gypi uses them. + args.append('-Dlinux_use_bundled_binutils=0') + args.append('-Dlinux_use_bundled_gold=0') + args.append('-Dlinux_use_gold_flags=0') + gyp_args = list(args) run_gyp(gyp_args)