summaryrefslogtreecommitdiff
path: root/vcbuild.bat
diff options
context:
space:
mode:
authorBartosz Sosnowski <bartosz@janeasystems.com>2018-06-06 18:22:50 +0200
committerBartosz Sosnowski <bartosz@janeasystems.com>2018-06-27 11:00:56 +0200
commit7c452845b8d44287f5db96a7f19e7d395e1899ab (patch)
treec382c10e329a2ad039c8dc162f93989be953eede /vcbuild.bat
parent8d33bbf16807e9219809f9528e8884a1c0a98277 (diff)
downloadandroid-node-v8-7c452845b8d44287f5db96a7f19e7d395e1899ab.tar.gz
android-node-v8-7c452845b8d44287f5db96a7f19e7d395e1899ab.tar.bz2
android-node-v8-7c452845b8d44287f5db96a7f19e7d395e1899ab.zip
build, win: make LTCG optional
Disables Link Time Code Generation by default. Adds ‘ltcg’ vcbuild option to enable it. LTCG will be used by default by release and CI builds. PR-URL: https://github.com/nodejs/node/pull/21186 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Diffstat (limited to 'vcbuild.bat')
-rw-r--r--vcbuild.bat8
1 files changed, 6 insertions, 2 deletions
diff --git a/vcbuild.bat b/vcbuild.bat
index af5c1a28e5..368112edf9 100644
--- a/vcbuild.bat
+++ b/vcbuild.bat
@@ -15,6 +15,7 @@ cd %~dp0
set config=Release
set target=Build
set target_arch=x64
+set ltcg=
set target_env=
set noprojgen=
set projgen=
@@ -61,7 +62,7 @@ set doc=
:next-arg
if "%1"=="" goto args-done
if /i "%1"=="debug" set config=Debug&goto arg-ok
-if /i "%1"=="release" set config=Release&goto arg-ok
+if /i "%1"=="release" set config=Release&set ltcg=1&goto arg-ok
if /i "%1"=="clean" set target=Clean&goto arg-ok
if /i "%1"=="ia32" set target_arch=x86&goto arg-ok
if /i "%1"=="x86" set target_arch=x86&goto arg-ok
@@ -75,6 +76,7 @@ if /i "%1"=="sign" set sign=1&goto arg-ok
if /i "%1"=="nosnapshot" set nosnapshot=1&goto arg-ok
if /i "%1"=="noetw" set noetw=1&goto arg-ok
if /i "%1"=="noperfctr" set noperfctr=1&goto arg-ok
+if /i "%1"=="ltcg" set ltcg=1&goto arg-ok
if /i "%1"=="licensertf" set licensertf=1&goto arg-ok
if /i "%1"=="test" set test_args=%test_args% -J %common_test_suites%&set lint_cpp=1&set lint_js=1&set lint_md=1&goto arg-ok
if /i "%1"=="test-ci" set test_args=%test_args% %test_ci_args% -p tap --logfile test.tap %common_test_suites%&set cctest_args=%cctest_args% --gtest_output=tap:cctest.tap&goto arg-ok
@@ -150,6 +152,7 @@ if defined build_release (
set download_arg="--download=all"
set i18n_arg=small-icu
set projgen=1
+ set ltcg=1
)
:: assign path to node_exe
@@ -162,6 +165,7 @@ if "%config%"=="Debug" set configure_flags=%configure_flags% --debug
if defined nosnapshot set configure_flags=%configure_flags% --without-snapshot
if defined noetw set configure_flags=%configure_flags% --without-etw& set noetw_msi_arg=/p:NoETW=1
if defined noperfctr set configure_flags=%configure_flags% --without-perfctr& set noperfctr_msi_arg=/p:NoPerfCtr=1
+if defined ltcg set configure_flags=%configure_flags% --with-ltcg
if defined release_urlbase set configure_flags=%configure_flags% --release-urlbase=%release_urlbase%
if defined download_arg set configure_flags=%configure_flags% %download_arg%
if defined enable_vtune_arg set configure_flags=%configure_flags% --enable-vtune-profiling
@@ -656,7 +660,7 @@ del .used_configure_flags
goto exit
:help
-echo vcbuild.bat [debug/release] [msi] [doc] [test/test-ci/test-all/test-addons/test-addons-napi/test-internet/test-pummel/test-simple/test-message/test-gc/test-tick-processor/test-known-issues/test-node-inspect/test-check-deopts/test-npm/test-async-hooks/test-v8/test-v8-intl/test-v8-benchmarks/test-v8-all] [ignore-flaky] [static/dll] [noprojgen] [projgen] [small-icu/full-icu/without-intl] [nobuild] [nosnapshot] [noetw] [noperfctr] [licensetf] [sign] [ia32/x86/x64] [vs2017] [download-all] [enable-vtune] [lint/lint-ci/lint-js/lint-js-ci/lint-md] [lint-md-build] [package] [build-release] [upload] [no-NODE-OPTIONS] [link-module path-to-module] [debug-http2] [debug-nghttp2] [clean] [no-cctest] [openssl-no-asm]
+echo vcbuild.bat [debug/release] [msi] [doc] [test/test-ci/test-all/test-addons/test-addons-napi/test-internet/test-pummel/test-simple/test-message/test-gc/test-tick-processor/test-known-issues/test-node-inspect/test-check-deopts/test-npm/test-async-hooks/test-v8/test-v8-intl/test-v8-benchmarks/test-v8-all] [ignore-flaky] [static/dll] [noprojgen] [projgen] [small-icu/full-icu/without-intl] [nobuild] [nosnapshot] [noetw] [noperfctr] [ltcg] [licensetf] [sign] [ia32/x86/x64] [vs2017] [download-all] [enable-vtune] [lint/lint-ci/lint-js/lint-js-ci/lint-md] [lint-md-build] [package] [build-release] [upload] [no-NODE-OPTIONS] [link-module path-to-module] [debug-http2] [debug-nghttp2] [clean] [no-cctest] [openssl-no-asm]
echo Examples:
echo vcbuild.bat : builds release build
echo vcbuild.bat debug : builds debug build