From 2d8d355a5f6791e75a08daf05229ad2075ad43a6 Mon Sep 17 00:00:00 2001 From: Myles Borins Date: Wed, 16 Aug 2017 14:38:47 -0700 Subject: [PATCH] build: re-enable snapshots in v8.x When 5d5e31c was backported to v8.x as e2b306c831 it was missing the configure changes from 8dce05fa7. This patch actually re-enables snapshots! Fixes: https://github.com/nodejs/node/issues/14870 PR-URL: https://github.com/nodejs/node/pull/14875 Reviewed-By: Anna Henningsen Reviewed-By: Michael Dawson Reviewed-By: James M Snell Reviewed-By: Gibson Fahnestock --- configure | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/configure b/configure index 0b9c3a16ed09ff..44ec5d2c472ed6 100755 --- a/configure +++ b/configure @@ -437,12 +437,12 @@ parser.add_option('--without-perfctr', # Dummy option for backwards compatibility parser.add_option('--with-snapshot', action='store_true', - dest='with_snapshot', + dest='unused_with_snapshot', help=optparse.SUPPRESS_HELP) parser.add_option('--without-snapshot', action='store_true', - dest='unused_without_snapshot', + dest='without_snapshot', help=optparse.SUPPRESS_HELP) parser.add_option('--without-ssl', @@ -827,7 +827,7 @@ def configure_node(o): cross_compiling = (options.cross_compiling if options.cross_compiling is not None else target_arch != host_arch) - want_snapshots = 1 if options.with_snapshot else 0 + want_snapshots = not options.without_snapshot o['variables']['want_separate_host_toolset'] = int( cross_compiling and want_snapshots) o['variables']['want_separate_host_toolset_mkpeephole'] = int( @@ -984,7 +984,7 @@ def configure_v8(o): o['variables']['v8_optimized_debug'] = 0 # Compile with -O0 in debug builds. o['variables']['v8_random_seed'] = 0 # Use a random seed for hash tables. o['variables']['v8_promise_internal_field_count'] = 1 # Add internal field to promises for async hooks. - o['variables']['v8_use_snapshot'] = b(options.with_snapshot) + o['variables']['v8_use_snapshot'] = 'false' if options.without_snapshot else 'true' o['variables']['v8_trace_maps'] = 1 if options.trace_maps else 0 o['variables']['node_use_v8_platform'] = b(not options.without_v8_platform) o['variables']['node_use_bundled_v8'] = b(not options.without_bundled_v8)