mirror of
https://github.com/electron/electron.git
synced 2026-02-12 08:05:07 -05:00
* chore: bump node in DEPS to v14.14.0 * Remove upstreamed certs patch https://github.com/nodejs/node/pull/35546 * Remove V8 Isolate callbacks patch https://github.com/nodejs/node/pull/35512 * Update patch indices * Update Node.js filenames Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
52 lines
1.9 KiB
Diff
52 lines
1.9 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Deepak Mohan <hop2deep@gmail.com>
|
|
Date: Wed, 16 Oct 2019 13:41:12 -0700
|
|
Subject: build: bring back node_with_ltcg configuration
|
|
|
|
This was moved to code node.gyp as part of https://github.com/nodejs/node/pull/25931
|
|
which caused native modules size increase which were depending on
|
|
this configuration transitively https://github.com/nodejs/node/issues/29501.
|
|
THe fix for this should land in node-gyp as discussed in above issue,
|
|
landing this as temporary patch.
|
|
|
|
diff --git a/common.gypi b/common.gypi
|
|
index 81568d5afabd6d80b4df445124ccd7108801769d..463adbfdd8fb3af5d19ed30461eae46fd647de1a 100644
|
|
--- a/common.gypi
|
|
+++ b/common.gypi
|
|
@@ -19,7 +19,7 @@
|
|
'node_use_v8_platform%': 'true',
|
|
'node_use_bundled_v8%': 'true',
|
|
'node_module_version%': '',
|
|
- 'node_with_ltcg%': '',
|
|
+ 'node_with_ltcg%': 'true',
|
|
'node_shared_openssl%': 'false',
|
|
|
|
'node_tag%': '',
|
|
@@ -232,6 +232,26 @@
|
|
'cflags': [ '-fPIC' ],
|
|
'ldflags': [ '-fPIC' ]
|
|
}],
|
|
+ ['node_with_ltcg=="true"', {
|
|
+ 'msvs_settings': {
|
|
+ 'VCCLCompilerTool': {
|
|
+ 'WholeProgramOptimization': 'true' # /GL, whole program optimization, needed for LTCG
|
|
+ },
|
|
+ 'VCLibrarianTool': {
|
|
+ 'AdditionalOptions': [
|
|
+ '/LTCG:INCREMENTAL', # incremental link-time code generation
|
|
+ ]
|
|
+ },
|
|
+ 'VCLinkerTool': {
|
|
+ 'OptimizeReferences': 2, # /OPT:REF
|
|
+ 'EnableCOMDATFolding': 2, # /OPT:ICF
|
|
+ 'LinkIncremental': 1, # disable incremental linking
|
|
+ 'AdditionalOptions': [
|
|
+ '/LTCG:INCREMENTAL', # incremental link-time code generation
|
|
+ ]
|
|
+ }
|
|
+ }
|
|
+ }]
|
|
],
|
|
'msvs_settings': {
|
|
'VCCLCompilerTool': {
|