]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-10436 [mod_v8] Upgrade javascript libv8 from 3.24.14 to 5.6.326 on windows.
authorAndrey Volk <andywolk@gmail.com>
Thu, 29 Jun 2017 00:04:18 +0000 (03:04 +0300)
committerAndrey Volk <andywolk@gmail.com>
Thu, 29 Jun 2017 00:04:18 +0000 (03:04 +0300)
libs/win32/Download V8.2015.vcxproj
libs/win32/v8/build-v8.bat
w32/v8-version.props
w32/v8.props

index 55f960d7516bd1de36e064330f815bf477d872b6..64ede7f2f7d93ddf90ef8425e8ab1360840af0a9 100644 (file)
     <CustomBuild Include="cleancount">\r
       <FileType>Document</FileType>\r
       <Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Downloading V8.</Message>\r
-      <Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">if not exist "$(ProjectDir)..\v8-$(V8Version)" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version)-vs2015.tar.bz2 "$(ProjectDir).."\r
+      <Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">if not exist "$(ProjectDir)..\v8-$(V8Version)" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version).tar.bz2 "$(ProjectDir).."\r
 if not exist "$(ProjectDir)..\v8-$(V8Version)\third_party\cygwin" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version)-win.tar.bz2 "$(ProjectDir).."\r
 </Command>\r
       <Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)..\v8-$(V8Version);%(Outputs)</Outputs>\r
       <Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Downloading V8.</Message>\r
-      <Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">if not exist "$(ProjectDir)..\v8-$(V8Version)" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version)-vs2015.tar.bz2 "$(ProjectDir).."\r
+      <Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">if not exist "$(ProjectDir)..\v8-$(V8Version)" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version).tar.bz2 "$(ProjectDir).."\r
 if not exist "$(ProjectDir)..\v8-$(V8Version)\third_party\cygwin" cscript /nologo "$(ProjectDir)util.vbs" GetUnzip http://files.freeswitch.org/downloads/libs/v8-$(V8Version)-win.tar.bz2 "$(ProjectDir).."\r
 </Command>\r
       <Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)..\v8-$(V8Version);%(Outputs)</Outputs>\r
index 6f0077b2d2ed51c856227daaad68bbb48a9d92eb..adcc81e02e48af8eefa0b48cc734c55e6cbb8873 100644 (file)
@@ -22,18 +22,28 @@ IF "%1-%2" == "%LAST_BUILD_INFO%" (
 )\r
 \r
 SET LIB_DEST_DIR=\r
+SET DEPOT_TOOLS_WIN_TOOLCHAIN=0\r
+SET GYP_GENERATORS=msvs\r
+REM Bake snapshot blobs (natives_blob.bin and snapshot_blob.bin) into the library\r
+SET GYPFLAGS="-Dv8_use_external_startup_data=0"\r
+\r
+CALL .\third_party\python_26\setup_env.bat\r
 \r
 IF "%VisualStudioVersion%" == "11.0" (\r
-       SET VS_VERSION=-Gmsvs_version=2012\r
+       REM SET VS_VERSION=-Gmsvs_version=2012\r
+        SET GYP_MSVS_VERSION=2012\r
        ECHO Forcing build to use Visual Studio 2012\r
 ) ELSE IF "%VisualStudioVersion%" == "12.0" (\r
-       SET VS_VERSION=-Gmsvs_version=2013\r
+       REM SET VS_VERSION=-Gmsvs_version=2013\r
+        SET GYP_MSVS_VERSION=2013\r
        ECHO Forcing build to use Visual Studio 2013\r
 ) ELSE IF "%VisualStudioVersion%" == "14.0" (\r
-       SET VS_VERSION=-Gmsvs_version=2015\r
+       REM SET VS_VERSION=-Gmsvs_version=2015\r
+        SET GYP_MSVS_VERSION=2015\r
        ECHO Forcing build to use Visual Studio 2015\r
 ) ELSE IF NOT "%4" == "" (\r
-       SET VS_VERSION=-Gmsvs_version=%4\r
+       REM SET VS_VERSION=-Gmsvs_version=%4\r
+        SET GYP_MSVS_VERSION=%4\r
        ECHO Forcing build to use Visual Studio %4\r
 )\r
 \r
@@ -46,13 +56,15 @@ IF "%1" == "x64" (
 \r
 IF "%1" == "x64" (\r
        IF NOT "%SKIP_V8_SNAPSHOT%" == "" ECHO Targeting x64 platform on a x86 system, disabling V8 snapshout feature to make this work [%SKIP_V8_SNAPSHOT%]\r
-       IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe build\gyp_v8 -Dtarget_arch=x64 -Dcomponent=shared_library %SKIP_V8_SNAPSHOT% %VS_VERSION%\r
+       REM IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe build\gyp_v8 -Dtarget_arch=x64 -Dcomponent=shared_library %SKIP_V8_SNAPSHOT% %VS_VERSION%\r
+       IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe gypfiles\gyp_v8 -Dtarget_arch=x64 -Dcomponent=shared_library %GYPFLAGS%\r
        IF ERRORLEVEL 1 GOTO Fail\r
        SET LIB_DEST_DIR=..\..\x64\%2\\r
 )\r
 \r
 IF "%1" == "x86" (\r
-       IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe build\gyp_v8 -Dcomponent=shared_library %VS_VERSION%\r
+       REM IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe build\gyp_v8 -Dcomponent=shared_library %VS_VERSION%\r
+       IF NOT "%COPY_FILES_ONLY%" == "1" .\third_party\python_26\python.exe gypfiles\gyp_v8 -Dcomponent=shared_library %GYPFLAGS%\r
        IF ERRORLEVEL 1 GOTO Fail\r
        SET LIB_DEST_DIR=..\..\Win32\%2\\r
 )\r
@@ -63,10 +75,12 @@ IF "%COPY_FILES_ONLY%" == "1" GOTO CopyFiles
 \r
 REM Clean build before we continue\r
 REM First try to clean using the solution path (works for most VS versions)\r
-msbuild "tools\gyp\v8.sln" /t:"_tools_\_gyp_\v8:Clean" /p:Configuration=%2 /clp:WarningsOnly\r
+REM msbuild "tools\gyp\v8.sln" /t:"_tools_\_gyp_\v8:Clean" /p:Configuration=%2 /clp:WarningsOnly\r
+msbuild "src\v8.sln" /t:"_src_\v8:Clean" /p:Configuration=%2 /clp:WarningsOnly\r
 IF NOT ERRORLEVEL 1 GOTO CleanDone\r
 REM If clean using solution path didn't work, try to build without the path (works for some VS versions...)\r
-msbuild "tools\gyp\v8.sln" /t:v8:Clean /p:Configuration=%2\r
+REM msbuild "tools\gyp\v8.sln" /t:v8:Clean /p:Configuration=%2\r
+msbuild "src\v8.sln" /t:v8:Clean /p:Configuration=%2\r
 IF ERRORLEVEL 1 GOTO Fail\r
 :CleanDone\r
 \r
@@ -75,10 +89,13 @@ rmdir /S /Q .\build\%2
 \r
 REM Build the V8 library\r
 REM First try to build using the solution path (works for most VS versions)\r
-msbuild "tools\gyp\v8.sln" /t:"_tools_\_gyp_\v8:Rebuild" /p:Configuration=%2 /clp:WarningsOnly\r
+REM msbuild "tools\gyp\v8.sln" /t:"_tools_\_gyp_\v8:Rebuild" /p:Configuration=%2 /clp:WarningsOnly\r
+REM msbuild "src\v8.sln" /t:"_src_\v8_libpaltfrom:Rebuild" /p:Configuration=%2 /clp:WarningsOnly\r
+msbuild "src\v8.sln" /t:"_src_\v8:Rebuild" /p:Configuration=%2 /clp:WarningsOnly\r
 IF NOT ERRORLEVEL 1 GOTO CopyFiles\r
 REM If build using solution path didn't work, try to build without the path (works for some VS versions...)\r
-msbuild "tools\gyp\v8.sln" /t:v8:Rebuild /p:Configuration=%2\r
+REM msbuild "tools\gyp\v8.sln" /t:v8:Rebuild /p:Configuration=%2\r
+msbuild "src\v8.sln" /t:v8:Rebuild /p:Configuration=%2\r
 IF ERRORLEVEL 1 GOTO Fail\r
 \r
 :CopyFiles\r
@@ -92,6 +109,12 @@ IF ERRORLEVEL 1 GOTO Fail
 xcopy /C /F /R /Y .\build\%2\v8.dll %LIB_DEST_DIR%\r
 IF ERRORLEVEL 1 GOTO Fail\r
 \r
+xcopy /C /F /R /Y .\build\%2\v8_libplatform.dll %LIB_DEST_DIR%\r
+IF ERRORLEVEL 1 GOTO Fail\r
+\r
+xcopy /C /F /R /Y .\build\%2\v8_libbase.dll %LIB_DEST_DIR%\r
+IF ERRORLEVEL 1 GOTO Fail\r
+\r
 ECHO %1-%2> last_build\r
 \r
 exit /b 0\r
index 800ab9a7e614504308cf7e86bd3c88bb3b5b4c5a..be5059ff9df75869c7f6123e4d2032d6b58fc6d4 100644 (file)
@@ -2,7 +2,7 @@
 <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
   <ImportGroup Label="PropertySheets" />\r
   <PropertyGroup Label="UserMacros">\r
-    <V8Version>3.24.14</V8Version>\r
+    <V8Version>5.6.326</V8Version>\r
   </PropertyGroup>\r
   <PropertyGroup>\r
     <V8VersionImported>true</V8VersionImported>\r
index 5476106df39266cbb94dee5f28048c236436a955..1368c703cd5238fa6f03ccbe963e267e715f71be 100644 (file)
@@ -13,7 +13,7 @@
     </ClCompile>\r
     <Link>\r
       <AdditionalLibraryDirectories>$(SolutionDir)libs\v8-$(V8Version)\build\$(Configuration)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
-      <AdditionalDependencies>icui18n.lib;icuuc.lib;v8.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
+      <AdditionalDependencies>icui18n.lib;icuuc.lib;v8.lib;v8_libplatform.lib;%(AdditionalDependencies)</AdditionalDependencies>\r
     </Link>\r
   </ItemDefinitionGroup>\r
 </Project>\r