Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit80749f7

Browse files
committed
Added changes for Visual Studio 2017
1 parentfde6a42 commit80749f7

8 files changed

+4793
-4
lines changed

‎build/helpers/dependencies.cmd

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,24 +13,41 @@ MKDIR %DOWNLOADS_DIR%
1313
if"%PRODUCT_NAME%"=="PostgreSQL"goto :SKIP_ZSTD
1414
if"%PRODUCT_NAME%"=="PostgresPro"goto :SKIP_ZSTD
1515

16+
IF%SDK%== MSVC2015 (
17+
SETWindowsTargetPlatformVersion=%WindowsSDKVersion%
18+
)
19+
IF%SDK%== MSVC2017 (
20+
SETWindowsTargetPlatformVersion=%WindowsSDKVersion%
21+
)
1622

1723
:ZSTD
24+
ECHOON
1825
TITLE"Building libzstd"
19-
setZSTD_RELEASE=1.1.0
26+
IF"ZSTD_RELEASE"==""setZSTD_RELEASE=1.1.0
2027
CD /D%DOWNLOADS_DIR%
2128
wget -O zstd-%ZSTD_RELEASE%.zip --no-check-certificate -c https://github.com/facebook/zstd/archive/v%ZSTD_RELEASE%.zip
2229
rm -rf%DEPENDENCIES_SRC_DIR%/zstd-%ZSTD_RELEASE%
2330
MKDIR%DEPENDENCIES_SRC_DIR%\zstd-%ZSTD_RELEASE%
2431
CD /D%DEPENDENCIES_SRC_DIR%
2532
7z x%DOWNLOADS_DIR%\zstd-%ZSTD_RELEASE%.zip
2633
CD zstd-%ZSTD_RELEASE%
34+
IF%SDK%== MSVC2017 (
35+
CD build/VS2010
36+
rem call "./../VS_Scripts/build.VS%REDIST_YEAR%.cmd"|| GOTO :ERROR
37+
rem call "./../VS_Scripts/build.generic.cmd" VS2017 x64 Release v141|| GOTO :ERROR
38+
msbuild zstd.sln /m /p:Configuration=Release /p:Platform=%Platform% /p:PlatformToolset=%PlatformToolset%||GOTO :ERROR
39+
CD ../..
40+
)ELSE (
2741
call build/VS_Scripts/build.VS%REDIST_YEAR%.cmd||GOTO :ERROR
42+
)
2843
MKDIR%DEPENDENCIES_BIN_DIR%\zstd
2944
cp lib\zstd.h%DEPENDENCIES_BIN_DIR%\zstd
3045
if%ARCH%== X86 (
3146
cp -va build/VS_Scripts/BIN/Release/Win32/zstdlib_x86*%DEPENDENCIES_BIN_DIR%\zstd
3247
)else (
3348
cp -va build/VS_Scripts/BIN/Release/x64/zstdlib_x64*%DEPENDENCIES_BIN_DIR%\zstd
49+
cp -va build/VS2010/bin/x64_Release/libzstd*%DEPENDENCIES_BIN_DIR%\zstd
50+
cp -va build/VS2010/bin/x64/Release/zstdlib_x64*%DEPENDENCIES_BIN_DIR%\zstd
3451
)
3552
7z a -r%DOWNLOADS_DIR%\%DEPS_ZIP%%DEPENDENCIES_BIN_DIR%\zstd
3653

@@ -99,7 +116,7 @@ tar xf libiconv-%ICONV_VER%.tar.gz -C %DEPENDENCIES_SRC_UDIR% || GOTO :ERROR
99116
CD /D%DEPENDENCIES_SRC_DIR%\libiconv-%ICONV_VER%*
100117
cp -v%ROOT%/patches/libiconv/libiconv-%ICONV_VER%-%SDK%.patch libiconv.patch
101118
patch -f -p0< libiconv.patch||GOTO :ERROR
102-
msbuild libiconv.vcxproj /m /p:Configuration=Release /p:Platform=%Platform% /p:PlatformToolset=%PlatformToolset%||GOTO :ERROR
119+
msbuild libiconv.vcxproj /m /p:Configuration=Release /p:Platform=%Platform% /p:PlatformToolset=%PlatformToolset%||GOTO :ERROR
103120
cp -av include%DEPENDENCIES_BIN_DIR%\iconv||GOTO :ERROR
104121
cp -av iconv.h%DEPENDENCIES_BIN_DIR%\iconv\include||GOTO :ERROR
105122
cp -av config.h%DEPENDENCIES_BIN_DIR%\iconv\include||GOTO :ERROR
@@ -242,7 +259,7 @@ tar xf gettext-%GETTEXT_VER%.tar.gz -C %DEPENDENCIES_SRC_UDIR% || GOTO :ERROR
242259
CD /D%DEPENDENCIES_SRC_DIR%\gettext-*
243260
cp -v%ROOT%/patches/gettext/gettext-%GETTEXT_VER%-%SDK%.patch gettext.patch
244261
patch -f -p0< gettext.patch||GOTO :ERROR
245-
msbuild libintl.vcxproj /m /p:Configuration=Release /p:Platform=%Platform% /p:PlatformToolset=%PlatformToolset%||GOTO :ERROR
262+
msbuild libintl.vcxproj /m /p:Configuration=Release /p:Platform=%Platform% /p:PlatformToolset=%PlatformToolset%||GOTO :ERROR
246263
MKDIR%DEPENDENCIES_BIN_DIR%\libintl\lib%DEPENDENCIES_BIN_DIR%\libintl\include
247264
cp -v Release*/*.dll%DEPENDENCIES_BIN_DIR%\libintl\lib||GOTO :ERROR
248265
cp -v Release*/*.lib%DEPENDENCIES_BIN_DIR%\libintl\lib||GOTO :ERROR

‎build/helpers/postgres.cmd

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
CALL%ROOT%\build\helpers\setvars.cmd
2-
32
IFEXIST%DOWNLOADS_DIR%\%DEPS_ZIP% (
43
7z x%DOWNLOADS_DIR%\%DEPS_ZIP% -o%DEPENDENCIES_BIN_DIR% -y
54
REM Go to last build
@@ -61,6 +60,12 @@ if "%PRODUCT_NAME%" == "PostgreSQL" (
6160
)
6261
)
6362

63+
IF%SDK%== MSVC2017 (
64+
cp -va%ROOT%/patches/postgresql/2017.patch .
65+
patch -p1< 2017.patch||GOTO :ERROR
66+
)
67+
68+
6469
:DONE_POSTGRESQL_PATCH
6570
>src\tools\msvc\config.plECHO use strict;
6671
>>src\tools\msvc\config.plECHO use warnings;

‎build/helpers/postgres_installer.cmd

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,14 @@ wget -c https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4
2626
wget -c https://download.microsoft.com/download/9/3/F/93FCF1E7-E6A4-478B-96E7-D4B285925B00/vc_redist.x64.exe -O"%BUILD_DIR%\vcredist\vcredist_x64_2015.exe"||GOTO :ERROR
2727
)
2828

29+
IF%REDIST_YEAR%==2017 (
30+
rem wget -c https://download.visualstudio.microsoft.com/download/pr/11100229/78c1e864d806e36f6035d80a0e80399e/VC_redist.x86.exe -O "%BUILD_DIR%\vcredist\vcredist_x86_2017.exe"|| GOTO :ERROR
31+
rem wget -c https://download.visualstudio.microsoft.com/download/pr/11100230/15ccb3f02745c7b206ad10373cbca89b/VC_redist.x64.exe -O "%BUILD_DIR%\vcredist\vcredist_x64_2017.exe"|| GOTO :ERROR
32+
rem VCToolsRedistDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Redist\MSVC\14.16.27012\
33+
cp"%VCToolsRedistDir%vc_redist.x86.exe""%BUILD_DIR%\vcredist\vcredist_x86_2017.exe"
34+
cp"%VCToolsRedistDir%vc_redist.x64.exe""%BUILD_DIR%\vcredist\vcredist_x64_2017.exe"
35+
)
36+
2937
REM Make directory for installers
3038
MKDIR"%BUILD_DIR%\installers"
3139

‎build/helpers/setvars.cmd

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,14 @@ IF %SDK% == MSVC2015 (
5454
IF%ARCH%== X64CALL"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall" amd64||GOTO :ERROR
5555
ECHOON
5656
)
57+
IF%SDK%== MSVC2017 (
58+
SETREDIST_YEAR=2017
59+
SETPlatformToolset=v141
60+
IF%ARCH%== X86CALL"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x86||GOTO :ERROR
61+
ECHOON
62+
IF%ARCH%== X64call"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" amd64||GOTO :ERROR
63+
)
64+
5765

5866
REM As we use Msys2 for build we need to install useful packages we will use
5967
@ECHO"Current PATH is:"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp