summaryrefslogtreecommitdiff
path: root/vcbuild.bat
diff options
context:
space:
mode:
authorBert Belder <bertbelder@gmail.com>2012-04-04 18:06:00 +0200
committerBert Belder <bertbelder@gmail.com>2012-04-04 18:14:21 +0200
commit2728dcc95bfaf9a4a084159e6f615238700c2060 (patch)
tree9779bd363454821e953330bb213889673ce5ec9f /vcbuild.bat
parent930fabe43f83343e7f1a41cbfa506cd08be6bfa5 (diff)
downloadandroid-node-v8-2728dcc95bfaf9a4a084159e6f615238700c2060.tar.gz
android-node-v8-2728dcc95bfaf9a4a084159e6f615238700c2060.tar.bz2
android-node-v8-2728dcc95bfaf9a4a084159e6f615238700c2060.zip
Windows: add build step that generates license.rtf from LICENSE
Diffstat (limited to 'vcbuild.bat')
-rw-r--r--vcbuild.bat18
1 files changed, 15 insertions, 3 deletions
diff --git a/vcbuild.bat b/vcbuild.bat
index fc4d94ea6d..92eef6feb6 100644
--- a/vcbuild.bat
+++ b/vcbuild.bat
@@ -24,6 +24,7 @@ set nosnapshot=
set test=
set test_args=
set msi=
+set licensertf=
set upload=
set jslint=
@@ -39,6 +40,7 @@ if /i "%1"=="noprojgen" set noprojgen=1&goto arg-ok
if /i "%1"=="nobuild" set nobuild=1&goto arg-ok
if /i "%1"=="nosign" set nosign=1&goto arg-ok
if /i "%1"=="nosnapshot" set nosnapshot=1&goto arg-ok
+if /i "%1"=="licensertf" set licensertf=1&goto arg-ok
if /i "%1"=="test-uv" set test=test-uv&goto arg-ok
if /i "%1"=="test-internet" set test=test-internet&goto arg-ok
if /i "%1"=="test-pummel" set test=test-pummel&goto arg-ok
@@ -46,7 +48,7 @@ if /i "%1"=="test-simple" set test=test-simple&goto arg-ok
if /i "%1"=="test-message" set test=test-message&goto arg-ok
if /i "%1"=="test-all" set test=test-all&goto arg-ok
if /i "%1"=="test" set test=test&goto arg-ok
-if /i "%1"=="msi" set msi=1&goto arg-ok
+if /i "%1"=="msi" set msi=1&set licensertf=1&goto arg-ok
if /i "%1"=="upload" set upload=1&goto arg-ok
if /i "%1"=="jslint" set jslint=1&goto arg-ok
@@ -74,7 +76,7 @@ echo Project files generated.
:msbuild
@rem Skip project generation if requested.
-if defined nobuild goto msi
+if defined nobuild goto sign
@rem Bail out early if not running in VS build env.
if defined VCINSTALLDIR goto msbuild-found
@@ -93,9 +95,19 @@ goto run
msbuild node.sln /m /t:%target% /p:Configuration=%config% /clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal /nologo
if errorlevel 1 goto exit
-if defined nosign goto msi
+:sign
+@rem Skip signing if the `nosign` option was specified.
+if defined nosign goto licensertf
+
signtool sign /a Release\node.exe
+:licensertf
+@rem Skip license.rtf generation if not requested.
+if not defined licensertf goto msi
+
+%config%\node tools\license2rtf.js < LICENSE > %config%\license.rtf
+if errorlevel 1 echo Failed to generate license.rtf&goto exit
+
:msi
@rem Skip msi generation if not requested
if not defined msi goto run