Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

gyp: allow pass v8 gyp variables to configure #6370

Closed
trevnorris opened this issue Oct 17, 2013 · 4 comments
Closed

gyp: allow pass v8 gyp variables to configure #6370

trevnorris opened this issue Oct 17, 2013 · 4 comments
Labels
Milestone

Comments

@trevnorris
Copy link

As far as I know, currently it's impossible to pass, say -Dv8_enable_i18n_support=1 to ./configure so it's read in as one of the variables in common.gypi. Is there a way, or will we need to add support for this?

/cc @tjfontaine @TooTallNate

@TooTallNate
Copy link

I'm not sure if it would be possible to add a generic -D handler with the python options parser we're using in ./configure, but we should probably do like what we do for like dtrace and the other optional compile-time features.

By that I mean add a --with-i18n switch. It should be pretty trivial to add that switch and have it map to -Dv8_enable_i18n_support=1 in the generated config.gypi file. Let me know if you need help with that.

@bnoordhuis
Copy link
Member

Is there a way, or will we need to add support for this?

os.environ['GYP_DEFINES'] = \
  os.environ.get('GYP_DEFINES', '') + ' v8_enable_i18n_support=1'

Right before calling into gyp?

@tjfontaine
Copy link

diff --git a/configure b/configure
index 4a38c70..4c49888 100755
--- a/configure
+++ b/configure
@@ -706,4 +706,6 @@ elif flavor == 'win':
 else:
   gyp_args = ['-f', 'make-' + flavor]

+gyp_args = gyp_args + args
+
 subprocess.call([sys.executable, 'tools/gyp_node.py'] + gyp_args)

then ./configure -- -Dv8_enable_i18n_support=1

if lgty I'll land

tjfontaine added a commit that referenced this issue Dec 7, 2013
use `--` to specify the arguments you want to pass directly to gyp.

for example: `./configure -- --no-parallel -Dsome_define=foo`

fixes #6370
@tjfontaine
Copy link

landed in b5e1619

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants