2013-01-07 20:34:03 +04:00
|
|
|
@echo off
|
2013-01-16 01:14:46 +04:00
|
|
|
setlocal
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: process arguments
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
|
2016-03-09 16:42:11 +03:00
|
|
|
set v8testedrev=4.9.385.30
|
2013-10-29 20:13:50 +04:00
|
|
|
|
2016-03-09 16:42:11 +03:00
|
|
|
set gyprev=b85ad3e578da830377dbc1843aa4fbc5af17a192
|
2015-05-09 15:00:44 +03:00
|
|
|
set cygwinrev=c89e446b273697fadf3a10ff1007a97c0b7de6df
|
2016-03-09 16:42:11 +03:00
|
|
|
set clangrev=24e8c1c92fe54ef8ed7651b5850c056983354a4a
|
|
|
|
set traceeventcommonrev=d83d44b13d07c2fd0a40101a7deef9b93b841732
|
2013-05-21 16:53:16 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:ProcessArgs
|
|
|
|
|
|
|
|
set download=true
|
|
|
|
set mode=Release
|
|
|
|
|
|
|
|
:ProcessArg
|
|
|
|
if "%1"=="" goto ProcessArgsDone
|
|
|
|
if "%1"=="/?" goto EchoUsage
|
|
|
|
if /i "%1"=="/n" goto SetDownloadFalse
|
2013-08-03 00:58:41 +04:00
|
|
|
if /i "%1"=="\n" goto SetDownloadFalse
|
|
|
|
if /i "%1"=="-n" goto SetDownloadFalse
|
2013-05-21 16:53:16 +04:00
|
|
|
if /i "%1"=="debug" goto SetDebugMode
|
|
|
|
if /i "%1"=="release" goto SetReleaseMode
|
|
|
|
goto SetV8Rev
|
2013-03-08 22:11:31 +04:00
|
|
|
|
|
|
|
:EchoUsage
|
|
|
|
echo Downloads, builds, and imports V8 for use with ClearScript.
|
|
|
|
echo.
|
2013-05-21 16:53:16 +04:00
|
|
|
echo V8UPDATE [/N] [mode] [revision]
|
2013-03-08 22:11:31 +04:00
|
|
|
echo.
|
2013-05-21 16:53:16 +04:00
|
|
|
echo /N Do not download; use previously downloaded files if possible.
|
2014-10-22 17:05:01 +04:00
|
|
|
echo mode Build mode: "Debug" or "Release" (default).
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
echo revision V8 revision: "Latest", "Tested" (default) or branch/commit/tag.
|
|
|
|
echo * Examples: "candidate", "3.29.88.16".
|
|
|
|
echo * View history at https://chromium.googlesource.com/v8/v8.git.
|
2013-03-08 22:11:31 +04:00
|
|
|
goto Exit
|
|
|
|
|
|
|
|
:SetDownloadFalse
|
|
|
|
set download=false
|
|
|
|
goto NextArg
|
2013-01-16 01:14:46 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:SetDebugMode
|
2013-01-07 20:34:03 +04:00
|
|
|
set mode=Debug
|
2013-03-08 22:11:31 +04:00
|
|
|
goto NextArg
|
|
|
|
:SetReleaseMode
|
2013-01-07 20:34:03 +04:00
|
|
|
set mode=Release
|
2013-03-08 22:11:31 +04:00
|
|
|
goto NextArg
|
|
|
|
|
2013-05-21 16:53:16 +04:00
|
|
|
:SetV8Rev
|
|
|
|
set v8rev=%1
|
|
|
|
goto NextArg
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:NextArg
|
|
|
|
shift
|
|
|
|
goto ProcessArg
|
|
|
|
|
|
|
|
:ProcessArgsDone
|
|
|
|
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: check environment
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
:CheckMSVS
|
|
|
|
if "%VisualStudioVersion%"=="12.0" goto UseMSVS2013
|
2015-08-16 19:42:51 +03:00
|
|
|
if "%VisualStudioVersion%"=="14.0" goto UseMSVS2015
|
|
|
|
echo Error: This script requires a Visual Studio 2013 or 2015 Developer Command
|
|
|
|
echo Prompt. Browse to http://www.visualstudio.com for more information.
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
goto Exit
|
|
|
|
:UseMSVS2013
|
|
|
|
set GYP_MSVS_VERSION=2013
|
2015-08-16 19:42:51 +03:00
|
|
|
goto CheckMSVSDone
|
|
|
|
:UseMSVS2015
|
|
|
|
set GYP_MSVS_VERSION=2015
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
:CheckMSVSDone
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: main
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
:Main
|
2013-01-07 20:34:03 +04:00
|
|
|
|
|
|
|
echo Build mode: %mode%
|
|
|
|
cd ClearScript\v8\v8
|
|
|
|
if errorlevel 1 goto Exit
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
if /i "%download%"=="true" goto Download
|
|
|
|
|
|
|
|
if exist build\ goto SkipDownload
|
|
|
|
echo *** BUILD DIRECTORY NOT FOUND; DOWNLOAD REQUIRED ***
|
|
|
|
choice /m Continue
|
|
|
|
if errorlevel 2 goto Exit
|
|
|
|
goto Download
|
|
|
|
|
|
|
|
:SkipDownload
|
|
|
|
cd build
|
|
|
|
goto Build
|
|
|
|
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: download
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
:Download
|
|
|
|
|
|
|
|
:ResolveRev
|
2013-07-03 00:52:43 +04:00
|
|
|
if "%v8rev%"=="" goto UseTestedRev
|
2013-05-21 16:53:16 +04:00
|
|
|
if /i "%v8rev%"=="latest" goto UseLatestRev
|
|
|
|
if /i "%v8rev%"=="tested" goto UseTestedRev
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if /i "%v8rev%"=="%v8testedrev%" goto UseTestedRev
|
2014-10-22 17:05:01 +04:00
|
|
|
echo V8 revision: %v8rev%
|
2013-08-03 00:58:41 +04:00
|
|
|
echo *** WARNING: THIS V8 REVISION MAY NOT BE COMPATIBLE WITH CLEARSCRIPT ***
|
|
|
|
choice /m Continue
|
|
|
|
if errorlevel 2 goto Exit
|
2013-03-08 22:11:31 +04:00
|
|
|
goto ResolveRevDone
|
2013-05-21 16:53:16 +04:00
|
|
|
:UseTestedRev
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
set v8rev=%v8testedrev%
|
|
|
|
echo V8 revision: Tested (%v8testedrev%)
|
2013-05-21 16:53:16 +04:00
|
|
|
goto ResolveRevDone
|
2013-03-08 22:11:31 +04:00
|
|
|
:UseLatestRev
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
set v8rev=master
|
2013-05-21 16:53:16 +04:00
|
|
|
echo V8 revision: Latest
|
2013-08-03 00:58:41 +04:00
|
|
|
echo *** WARNING: THIS V8 REVISION MAY NOT BE COMPATIBLE WITH CLEARSCRIPT ***
|
|
|
|
choice /m Continue
|
|
|
|
if errorlevel 2 goto Exit
|
2013-03-08 22:11:31 +04:00
|
|
|
:ResolveRevDone
|
|
|
|
|
|
|
|
:EnsureBuildDir
|
2013-01-07 20:34:03 +04:00
|
|
|
if not exist build\ goto CreateBuildDir
|
|
|
|
echo Removing old build directory ...
|
|
|
|
rd /s /q build
|
|
|
|
:CreateBuildDir
|
2013-01-16 01:14:46 +04:00
|
|
|
echo Creating build directory ...
|
2013-01-07 20:34:03 +04:00
|
|
|
md build
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:EnsureBuildDirDone
|
|
|
|
|
2013-01-07 20:34:03 +04:00
|
|
|
cd build
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadV8
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Downloading V8 ...
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
git clone -n -q https://chromium.googlesource.com/v8/v8.git
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd v8
|
|
|
|
git checkout -q "%v8rev%"
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd ..
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadV8Done
|
|
|
|
|
2013-01-07 20:34:03 +04:00
|
|
|
cd v8
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:PatchV8
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Patching V8 ...
|
2015-05-09 15:00:44 +03:00
|
|
|
git apply --ignore-whitespace ..\..\V8Patch.txt 2>applyPatch.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:PatchV8Done
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadGYP
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Downloading GYP ...
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
git clone -n -q https://chromium.googlesource.com/external/gyp.git build\gyp
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd build\gyp
|
|
|
|
git checkout -q "%gyprev%"
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd ..\..
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadGYPDone
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadCygwin
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Downloading Cygwin ...
|
2015-12-07 14:57:35 +03:00
|
|
|
git clone -n -q https://chromium.googlesource.com/chromium/deps/cygwin.git third_party\cygwin
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd third_party/cygwin
|
|
|
|
git checkout -q "%cygwinrev%"
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd ..\..
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadCygwinDone
|
|
|
|
|
2016-03-09 16:42:11 +03:00
|
|
|
:DownloadClang
|
|
|
|
echo Downloading Clang ...
|
|
|
|
git clone -n -q https://chromium.googlesource.com/chromium/src/tools/clang.git tools\clang
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd tools\clang
|
|
|
|
git checkout -q "%clangrev%"
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd ..\..
|
|
|
|
:DownloadClangDone
|
|
|
|
|
|
|
|
:DownloadTraceEventCommon
|
|
|
|
echo Downloading TraceEventCommon ...
|
|
|
|
git clone -n -q https://chromium.googlesource.com/chromium/src/base/trace_event/common.git base/trace_event/common
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd base/trace_event/common
|
|
|
|
git checkout -q "%traceeventcommonrev%"
|
|
|
|
if errorlevel 1 goto Error
|
|
|
|
cd ..\..\..
|
|
|
|
:DownloadTraceEventCommonDone
|
|
|
|
|
2013-01-07 20:34:03 +04:00
|
|
|
cd ..
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:DownloadDone
|
|
|
|
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: build
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
:Build
|
|
|
|
|
2015-12-07 14:57:35 +03:00
|
|
|
set DEPOT_TOOLS_WIN_TOOLCHAIN=0
|
|
|
|
|
2013-10-14 19:15:37 +04:00
|
|
|
:CreatePatchFile
|
|
|
|
echo Creating patch file ...
|
|
|
|
cd v8
|
2015-05-09 15:00:44 +03:00
|
|
|
git diff --ignore-space-change --ignore-space-at-eol >V8Patch.txt 2>createPatch.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-10-14 19:15:37 +04:00
|
|
|
cd ..
|
|
|
|
:CreatePatchFileDone
|
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:Copy32Bit
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Building 32-bit V8 ...
|
2013-03-08 22:11:31 +04:00
|
|
|
if exist v8-ia32\ goto Copy32BitDone
|
2013-01-07 20:34:03 +04:00
|
|
|
md v8-ia32
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
xcopy v8\*.* v8-ia32\ /e /y >nul
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:Copy32BitDone
|
|
|
|
|
|
|
|
:Build32Bit
|
2013-01-07 20:34:03 +04:00
|
|
|
cd v8-ia32
|
2015-05-09 15:00:44 +03:00
|
|
|
python build\gyp_v8 -Dtarget_arch=ia32 -Dcomponent=shared_library -Dv8_use_snapshot=false -Dv8_enable_i18n_support=0 >gyp.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-27 06:34:31 +04:00
|
|
|
msbuild /p:Configuration=%mode% /p:Platform=Win32 /t:v8 tools\gyp\v8.sln >build.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
cd ..
|
2013-03-08 22:11:31 +04:00
|
|
|
:Build32BitDone
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:Copy64Bit
|
2013-01-07 20:34:03 +04:00
|
|
|
echo Building 64-bit V8 ...
|
2013-03-08 22:11:31 +04:00
|
|
|
if exist v8-x64\ goto Copy64BitDone
|
2013-01-07 20:34:03 +04:00
|
|
|
md v8-x64
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
xcopy v8\*.* v8-x64\ /e /y >nul
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:Copy64BitDone
|
|
|
|
|
|
|
|
:Build64Bit
|
2013-01-07 20:34:03 +04:00
|
|
|
cd v8-x64
|
2015-05-09 15:00:44 +03:00
|
|
|
python build\gyp_v8 -Dtarget_arch=x64 -Dcomponent=shared_library -Dv8_use_snapshot=false -Dv8_enable_i18n_support=0 >gyp.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-27 06:34:31 +04:00
|
|
|
msbuild /p:Configuration=%mode% /p:Platform=x64 /t:v8 tools\gyp\v8.sln >build.log
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
cd ..
|
|
|
|
:Build64BitDone
|
|
|
|
|
|
|
|
:BuildDone
|
|
|
|
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: import
|
|
|
|
::-----------------------------------------------------------------------------
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:Import
|
|
|
|
|
|
|
|
cd ..
|
|
|
|
|
|
|
|
:EnsureLibDir
|
2013-01-07 20:34:03 +04:00
|
|
|
if not exist lib\ goto CreateLibDir
|
|
|
|
echo Removing old lib directory ...
|
|
|
|
rd /s /q lib
|
|
|
|
:CreateLibDir
|
2013-01-16 01:14:46 +04:00
|
|
|
echo Creating lib directory ...
|
2013-01-07 20:34:03 +04:00
|
|
|
md lib
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:EnsureLibDirDone
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:ImportLibs
|
2013-01-16 18:00:57 +04:00
|
|
|
echo Importing V8 libraries ...
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-ia32\build\%mode%\v8-ia32.dll lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-ia32\build\%mode%\v8-ia32.pdb lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-ia32\build\%mode%\lib\v8-ia32.lib lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-x64\build\%mode%\v8-x64.dll lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-x64\build\%mode%\v8-x64.pdb lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8-x64\build\%mode%\lib\v8-x64.lib lib\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:ImportLibsDone
|
2013-01-16 18:00:57 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:EnsureIncludeDir
|
2013-01-16 18:00:57 +04:00
|
|
|
if not exist include\ goto CreateIncludeDir
|
|
|
|
echo Removing old include directory ...
|
|
|
|
rd /s /q include
|
|
|
|
:CreateIncludeDir
|
|
|
|
echo Creating include directory ...
|
|
|
|
md include
|
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:EnsureIncludeDirDone
|
2013-01-16 18:00:57 +04:00
|
|
|
|
2013-03-08 22:11:31 +04:00
|
|
|
:ImportHeaders
|
2013-01-16 18:00:57 +04:00
|
|
|
echo Importing V8 header files ...
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8\include\*.* include\ >nul
|
2013-01-16 01:14:46 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-03-08 22:11:31 +04:00
|
|
|
:ImportHeadersDone
|
2013-01-16 18:00:57 +04:00
|
|
|
|
2013-10-14 19:15:37 +04:00
|
|
|
:ImportPatchFile
|
|
|
|
echo Importing patch file ...
|
2013-01-07 20:34:03 +04:00
|
|
|
copy build\v8\V8Patch.txt .\ >nul
|
2013-01-16 18:00:57 +04:00
|
|
|
if errorlevel 1 goto Error
|
2013-10-14 19:15:37 +04:00
|
|
|
:ImportPatchFileDone
|
2013-03-08 22:11:31 +04:00
|
|
|
|
|
|
|
:ImportDone
|
|
|
|
|
|
|
|
::-----------------------------------------------------------------------------
|
|
|
|
:: exit
|
|
|
|
::-----------------------------------------------------------------------------
|
2013-01-16 18:00:57 +04:00
|
|
|
|
2013-02-02 21:46:38 +04:00
|
|
|
echo Succeeded!
|
Version 5.4.1: Implemented a V8 debug agent to compensate for removed V8 API, V8Update now fetches V8 source and dependencies from Git repositories, fixed V8 assembly unloading and patched V8 to tolerate redundant initialization (Issue #60), added ScriptEngine.EnableAutoHostVariables, fixed by-reference arguments to VBScript functions (Issue #58), removed support for Visual Studio 2012 (V8 build now requires at least Visual Studio 2013), added explicit loading of primary interop assemblies to fix Issue #68, added host exception marshaling for V8, fixed V8ScriptEngine crash when script code calls the HostObject constructor, fixed host item caching for host variables, added non-generic overloads of newArr() and func() to HostFunctions, added ScriptEngine.Current, HostFunctions instances can now be exposed in multiple script engines, added a GetDynamicMemberNames() override to MetaScriptItem (Issue #64), fixed indexed property binding ambiguity for inherited interfaces (Issue #69), added tests for bug fixes and new APIs. Tested with V8 3.30.33.16.
2015-02-06 07:35:44 +03:00
|
|
|
goto Exit
|
2013-01-07 20:34:03 +04:00
|
|
|
|
2013-01-16 01:14:46 +04:00
|
|
|
:Error
|
|
|
|
echo *** THE PREVIOUS STEP FAILED ***
|
2013-01-07 20:34:03 +04:00
|
|
|
|
|
|
|
:Exit
|
2013-01-16 01:14:46 +04:00
|
|
|
endlocal
|