Skip to content

Commit b5e1619

Browse files
committed
build: ./configure pass positional args to gyp
use `--` to specify the arguments you want to pass directly to gyp. for example: `./configure -- --no-parallel -Dsome_define=foo` fixes #6370
1 parent 5cfee92 commit b5e1619

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

configure

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -695,13 +695,17 @@ config = '\n'.join(map('='.join, config.iteritems())) + '\n'
695695
write('config.mk',
696696
'# Do not edit. Generated by the configure script.\n' + config)
697697

698+
gyp_args = [sys.executable, 'tools/gyp_node.py']
699+
698700
if options.use_ninja:
699-
gyp_args = ['-f', 'ninja-' + flavor]
701+
gyp_args += ['-f', 'ninja-' + flavor]
700702
elif options.use_xcode:
701-
gyp_args = ['-f', 'xcode']
703+
gyp_args += ['-f', 'xcode']
702704
elif flavor == 'win':
703-
gyp_args = ['-f', 'msvs', '-G', 'msvs_version=auto']
705+
gyp_args += ['-f', 'msvs', '-G', 'msvs_version=auto']
704706
else:
705-
gyp_args = ['-f', 'make-' + flavor]
707+
gyp_args += ['-f', 'make-' + flavor]
708+
709+
gyp_args += args
706710

707-
subprocess.call([sys.executable, 'tools/gyp_node.py'] + gyp_args)
711+
subprocess.call(gyp_args)

0 commit comments

Comments
 (0)