Skip to content

Commit 5245d37

Browse files
committed
Compiling: Switch to Visual Studio 2017
1 parent 69fc4bf commit 5245d37

File tree

7 files changed

+124
-380
lines changed

7 files changed

+124
-380
lines changed

C/7zVersion.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#define MY_VERSION_CPU MY_VERSION
1111
#endif
1212

13-
#define MY_DATE "2020-04-10"
13+
#define MY_DATE "2020-04-11"
1414
#undef MY_COPYRIGHT
1515
#undef MY_VERSION_COPYRIGHT_DATE
1616
#define MY_AUTHOR_NAME "Igor Pavlov, Tino Reichardt"

CPP/appveyor.cmd

Lines changed: 20 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,44 @@
11
@echo off
22

33
REM Microsoft Windows SDK 7.1 (VC=sdk71) -> can compile for IA64, but who needs that?
4-
REM Microsoft Visual Studio 2010 (VC=10.0) -> for win2k
4+
REM Microsoft Visual Studio 2010 (VC=10.0) -> for win2k, but who needs that?
55
REM Microsoft Visual Studio 2012 (VC=11.0)
66
REM Microsoft Visual Studio 2013 (VC=12.0)
77
REM Microsoft Visual Studio 2015 (VC=14.0)
8-
REM Microsoft Visual Studio 2017 (VC=15.0) -> for: x32 + x64
8+
REM Microsoft Visual Studio 2017 (VC=15.0)
99

1010
REM to many vcvarsall.cmd calls will blow it up!
1111
set OPATH=%PATH%
1212
set ERRFILE=%APPVEYOR_BUILD_FOLDER%\error.txt
1313
cd %APPVEYOR_BUILD_FOLDER%\CPP
1414

15-
REM releases now:
16-
REM sdk71: ia builds
17-
REM vc10: win2k builds
18-
REM vc14: >= winxp builds
19-
REM /TR 2019-09-07
20-
goto vc14
15+
goto build_vs2017
2116

22-
:sdk71
23-
set VC=sdk71
24-
set NEXT=vc10
25-
goto build_sdk
26-
27-
:vc10
28-
set VC=10.0
29-
set NEXT=vc14
30-
set CFLAGS=
31-
goto build_vc
32-
33-
:vc11
34-
set VC=11.0
35-
set NEXT=end
36-
set CFLAGS=-Gw
37-
goto build_vc
38-
39-
:vc12
40-
set VC=12.0
41-
set NEXT=end
42-
set CFLAGS=-Gw
43-
goto build_vc
44-
45-
:vc14
46-
set VC=14.0
47-
set NEXT=end
48-
set CFLAGS=-Gw
49-
goto build_vc
50-
51-
52-
:build_sdk
17+
:build_vs2017
18+
set VC=15.0
5319
set PATH=%OPATH%
5420
set SUBSYS="5.01"
55-
call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" x86
56-
call "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /Release /ia64 /xp
57-
set OUTDIR=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-ia64
58-
call build-ia64.cmd
59-
goto %NEXT%
21+
set OPTS=MY_STATIC_LINK=1 /NOLOGO
22+
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x86
23+
call build-it.cmd
6024

61-
:build_vc
62-
FOR /R .\ %%d IN (ARM X64 O) DO rd /S /Q %%d 2>NUL
63-
set PATH=%OPATH%
64-
set SUBSYS="5.01"
65-
call "C:\Program Files (x86)\Microsoft Visual Studio %VC%\VC\vcvarsall.bat" x86
66-
set OUTDIR=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-x32
67-
call build-x32.cmd
6825
set PATH=%OPATH%
6926
set SUBSYS="5.02"
70-
call "C:\Program Files (x86)\Microsoft Visual Studio %VC%\VC\vcvarsall.bat" x86_amd64
71-
set OUTDIR=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-x64
72-
call build-x64.cmd
27+
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64
28+
call build-it.cmd
29+
30+
set PATH=%OPATH%
31+
set SUBSYS="6.02"
32+
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64_arm
33+
call build-it.cmd
34+
7335
set PATH=%OPATH%
7436
set SUBSYS="6.02"
75-
call "C:\Program Files (x86)\Microsoft Visual Studio %VC%\VC\vcvarsall.bat" x86_arm
76-
set OUTDIR=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-arm
77-
call build-arm.cmd
78-
goto %NEXT%
37+
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64_arm64
38+
call build-it.cmd
39+
40+
goto end
7941

8042
:end
8143
cd %APPVEYOR_BUILD_FOLDER%
82-
set > env.txt
8344
7z a %APPVEYOR_PROJECT_NAME%-%APPVEYOR_BUILD_VERSION%.7z bin-* *.txt

CPP/build-arm.cmd

Lines changed: 0 additions & 101 deletions
This file was deleted.

CPP/build-it.cmd

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
@echo off
2+
3+
set ROOT=%cd%\7zip
4+
set OUTDIR=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-%PLATFORM%
5+
set ERRFILE=%APPVEYOR_BUILD_FOLDER%\bin-%VC%-%PLATFORM%.log
6+
set LFLAGS=/SUBSYSTEM:WINDOWS,%SUBSYS%
7+
set > %APPVEYOR_BUILD_FOLDER%\env-%VC%-%PLATFORM%.txt
8+
mkdir %OUTDIR%
9+
10+
cd %ROOT%\Bundles\Format7zExtract
11+
nmake %OPTS%
12+
IF %errorlevel% NEQ 0 echo "Error @ 7zxa.dll" >> %ERRFILE%
13+
copy %PLATFORM%\7zxa.dll %OUTDIR%\7zxa.dll
14+
15+
cd %ROOT%\Bundles\Format7z
16+
nmake %OPTS%
17+
IF %errorlevel% NEQ 0 echo "Error @ 7za.dll" >> %ERRFILE%
18+
copy %PLATFORM%\7za.dll %OUTDIR%\7za.dll
19+
20+
cd %ROOT%\Bundles\Format7zF
21+
nmake %OPTS%
22+
IF %errorlevel% NEQ 0 echo "Error @ 7z.dll" >> %ERRFILE%
23+
copy %PLATFORM%\7z.dll %OUTDIR%\7z.dll
24+
25+
cd %ROOT%\UI\FileManager
26+
nmake %OPTS%
27+
IF %errorlevel% NEQ 0 echo "Error @ 7zFM.exe" >> %ERRFILE%
28+
copy %PLATFORM%\7zFM.exe %OUTDIR%\7zFM.exe
29+
30+
cd %ROOT%\UI\GUI
31+
nmake %OPTS%
32+
IF %errorlevel% NEQ 0 echo "Error @ 7zG.exe" >> %ERRFILE%
33+
copy %PLATFORM%\7zG.exe %OUTDIR%\7zG.exe
34+
35+
cd %ROOT%\UI\Explorer
36+
nmake %OPTS%
37+
IF %errorlevel% NEQ 0 echo "Error @ 7-zip.dll" >> %ERRFILE%
38+
copy %PLATFORM%\7-zip.dll %OUTDIR%\7-zip.dll
39+
40+
cd %ROOT%\Bundles\SFXWin
41+
nmake %OPTS%
42+
IF %errorlevel% NEQ 0 echo "Error @ 7z.sfx" >> %ERRFILE%
43+
copy %PLATFORM%\7z.sfx %OUTDIR%\7z.sfx
44+
45+
cd %ROOT%\Bundles\Codec_brotli
46+
nmake %OPTS%
47+
IF %errorlevel% NEQ 0 echo "Error @ brotli.dll" >> %ERRFILE%
48+
copy %PLATFORM%\brotli.dll %OUTDIR%\brotli.dll
49+
50+
cd %ROOT%\Bundles\Codec_lizard
51+
nmake %OPTS%
52+
IF %errorlevel% NEQ 0 echo "Error @ lizard.dll" >> %ERRFILE%
53+
copy %PLATFORM%\lizard.dll %OUTDIR%\lizard.dll
54+
55+
cd %ROOT%\Bundles\Codec_lz4
56+
nmake %OPTS%
57+
IF %errorlevel% NEQ 0 echo "Error @ lz4.dll" >> %ERRFILE%
58+
copy %PLATFORM%\lz4.dll %OUTDIR%\lz4.dll
59+
60+
cd %ROOT%\Bundles\Codec_lz5
61+
nmake %OPTS%
62+
IF %errorlevel% NEQ 0 echo "Error @ lz5.dll" >> %ERRFILE%
63+
copy %PLATFORM%\lz5.dll %OUTDIR%\lz5.dll
64+
65+
cd %ROOT%\Bundles\Codec_zstd
66+
nmake %OPTS%
67+
IF %errorlevel% NEQ 0 echo "Error @ zstd.dll" >> %ERRFILE%
68+
copy %PLATFORM%\zstd.dll %OUTDIR%\zstd.dll
69+
70+
cd %ROOT%\Bundles\Codec_flzma2
71+
nmake %OPTS%
72+
IF %errorlevel% NEQ 0 echo "Error @ flzma2.dll" >> %ERRFILE%
73+
copy %PLATFORM%\flzma2.dll %OUTDIR%\flzma2.dll
74+
75+
cd %ROOT%\..\..\C\Util\7zipInstall
76+
nmake %OPTS%
77+
IF %errorlevel% NEQ 0 echo "Error @ Install.exe" >> %ERRFILE%
78+
copy %PLATFORM%\7zipInstall.exe %OUTDIR%\Install.exe
79+
80+
cd %ROOT%\..\..\C\Util\7zipUninstall
81+
nmake %OPTS%
82+
IF %errorlevel% NEQ 0 echo "Error @ Uninstall.exe" >> %ERRFILE%
83+
copy %PLATFORM%\7zipUninstall.exe %OUTDIR%\Uninstall.exe
84+
85+
set LFLAGS=/SUBSYSTEM:CONSOLE,%SUBSYS%
86+
cd %ROOT%\UI\Console
87+
nmake %OPTS%
88+
IF %errorlevel% NEQ 0 echo "Error @ 7z.exe" >> %ERRFILE%
89+
copy %PLATFORM%\7z.exe %OUTDIR%\7z.exe
90+
91+
cd %ROOT%\Bundles\SFXCon
92+
nmake %OPTS%
93+
IF %errorlevel% NEQ 0 echo "Error @ 7zCon.sfx" >> %ERRFILE%
94+
copy %PLATFORM%\7zCon.sfx %OUTDIR%\7zCon.sfx
95+
96+
cd %ROOT%\Bundles\Alone
97+
nmake %OPTS%
98+
IF %errorlevel% NEQ 0 echo "Error @ 7za.exe" >> %ERRFILE%
99+
copy %PLATFORM%\7za.exe %OUTDIR%\7za.exe
100+
101+
:ende
102+
cd %ROOT%\..
103+

0 commit comments

Comments
 (0)