/
appveyor.bat
executable file
·156 lines (144 loc) · 6.14 KB
/
appveyor.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
@echo off
:: Batch file for building/testing Vim on AppVeyor
if /I "%1"=="" (
set target=build
) else (
set target=%1
)
goto %target%_%ARCH%
echo Unknown build target.
exit 1
:install_x86
:: ----------------------------------------------------------------------
@echo on
:: Work around for Python 2.7.11
reg copy HKLM\SOFTWARE\Python\PythonCore\2.7 HKLM\SOFTWARE\Python\PythonCore\2.7-32 /s /reg:32
:: Lua
:: Appveyor command doesn't seem to work well when downloading from sf.net.
curl -L "http://downloads.sourceforge.net/project/luabinaries/5.3.2/Windows%%20Libraries/Dynamic/lua-5.3.2_Win32_dllw4_lib.zip" -o lua.zip
7z x lua.zip -oC:\Lua > nul
:: Perl
appveyor DownloadFile http://downloads.activestate.com/ActivePerl/releases/5.22.0.2200/ActivePerl-5.22.0.2200-MSWin32-x86-64int-299195.zip -FileName perl.zip
7z x perl.zip -oC:\ > nul
for /d %%i in (C:\ActivePerl*) do move %%i C:\Perl522
:: Tcl
appveyor DownloadFile http://downloads.activestate.com/ActiveTcl/releases/8.6.4.1/ActiveTcl8.6.4.1.299124-win32-ix86-threaded.exe -FileName tcl.exe
start /wait tcl.exe --directory C:\Tcl
:: Ruby
:: RubyInstaller is built by MinGW, so we cannot use header files from it.
:: Download the source files and generate config.h for MSVC.
git clone https://github.com/ruby/ruby.git -b ruby_2_2 --depth 1 -q ../ruby
pushd ..\ruby
call win32\configure.bat
nmake .config.h.time
popd
:: Update PATH
path C:\Perl522\perl\bin;%path%;C:\Lua;C:\Tcl\bin;C:\Ruby22\bin
@echo off
goto :eof
:install_x64
:: ----------------------------------------------------------------------
@echo on
:: Work around for Python 2.7.11
reg copy HKLM\SOFTWARE\Python\PythonCore\2.7 HKLM\SOFTWARE\Python\PythonCore\2.7-32 /s /reg:64
:: Lua
:: Appveyor command doesn't seem to work well when downloading from sf.net.
curl -L "http://downloads.sourceforge.net/project/luabinaries/5.3.2/Windows%%20Libraries/Dynamic/lua-5.3.2_Win64_dllw4_lib.zip" -o lua.zip
7z x lua.zip -oC:\Lua > nul
:: Perl
appveyor DownloadFile http://downloads.activestate.com/ActivePerl/releases/5.22.0.2200/ActivePerl-5.22.0.2200-MSWin32-x64-299195.zip -FileName perl.zip
7z x perl.zip -oC:\ > nul
for /d %%i in (C:\ActivePerl*) do move %%i C:\Perl522
:: Tcl
appveyor DownloadFile http://downloads.activestate.com/ActiveTcl/releases/8.6.4.1/ActiveTcl8.6.4.1.299124-win32-x86_64-threaded.exe -FileName tcl.exe
start /wait tcl.exe --directory C:\Tcl
:: Ruby
:: RubyInstaller is built by MinGW, so we cannot use header files from it.
:: Download the source files and generate config.h for MSVC.
git clone https://github.com/ruby/ruby.git -b ruby_2_2 --depth 1 -q ../ruby
pushd ..\ruby
call win32\configure.bat
nmake .config.h.time
popd
:: Update PATH
path C:\Perl522\perl\bin;%path%;C:\Lua;C:\Tcl\bin;C:\Ruby22-x64\bin
@echo off
goto :eof
:build_x86
:: ----------------------------------------------------------------------
@echo on
:: Remove progress bar from the build log
sed -e "s/\$(LINKARGS2)/\$(LINKARGS2) | sed -e 's#.*\\\\r.*##'/" Make_mvc.mak > Make_mvc2.mak
:: Build GUI version
nmake -f Make_mvc2.mak CPU=i386 ^
GUI=yes OLE=no DIRECTX=yes ^
FEATURES=HUGE IME=yes MBYTE=yes ICONV=yes DEBUG=no ^
PERL_VER=522 DYNAMIC_PERL=yes PERL=C:\Perl522\perl ^
PYTHON_VER=27 DYNAMIC_PYTHON=yes PYTHON=C:\Python27 ^
PYTHON3_VER=34 DYNAMIC_PYTHON3=yes PYTHON3=C:\Python34 ^
LUA_VER=53 DYNAMIC_LUA=yes LUA=C:\Lua ^
TCL_VER=86 DYNAMIC_TCL=yes TCL=C:\Tcl ^
RUBY=C:\projects\ruby DYNAMIC_RUBY=yes RUBY_VER=22 RUBY_VER_LONG=2.2.0 ^
RUBY_INSTALL_NAME=msvcrt-ruby$(RUBY_API_VER) RUBY_PLATFORM=i386-mswin32_100 ^
RUBY_INC="/I $(RUBY)\include /I $(RUBY)\.ext\include\$(RUBY_PLATFORM)" ^
WINVER=0x500 ^
|| exit 1
:: Build CUI version
nmake -f Make_mvc2.mak CPU=i386 ^
GUI=no OLE=no DIRECTX=no ^
FEATURES=HUGE IME=yes MBYTE=yes ICONV=yes DEBUG=no ^
PERL_VER=522 DYNAMIC_PERL=yes PERL=C:\Perl522\perl ^
PYTHON_VER=27 DYNAMIC_PYTHON=yes PYTHON=C:\Python27 ^
PYTHON3_VER=34 DYNAMIC_PYTHON3=yes PYTHON3=C:\Python34 ^
LUA_VER=53 DYNAMIC_LUA=yes LUA=C:\Lua ^
TCL_VER=86 DYNAMIC_TCL=yes TCL=C:\Tcl ^
RUBY=C:\projects\ruby DYNAMIC_RUBY=yes RUBY_VER=22 RUBY_VER_LONG=2.2.0 ^
RUBY_INSTALL_NAME=msvcrt-ruby$(RUBY_API_VER) RUBY_PLATFORM=i386-mswin32_100 ^
RUBY_INC="/I $(RUBY)\include /I $(RUBY)\.ext\include\$(RUBY_PLATFORM)" ^
WINVER=0x500 ^
|| exit 1
:: Build translations
pushd po
nmake -f Make_mvc.mak GETTEXT_PATH=C:\cygwin\bin VIMRUNTIME=..\..\runtime install-all || exit 1
popd
@echo off
goto :eof
:build_x64
:: ----------------------------------------------------------------------
@echo on
:: Remove progress bar from the build log
sed -e "s/\$(LINKARGS2)/\$(LINKARGS2) | sed -e 's#.*\\\\r.*##'/" Make_mvc.mak > Make_mvc2.mak
:: Build GUI version
nmake -f Make_mvc2.mak CPU=AMD64 ^
GUI=yes OLE=no DIRECTX=yes ^
FEATURES=HUGE IME=yes MBYTE=yes ICONV=yes DEBUG=no ^
PERL_VER=522 DYNAMIC_PERL=yes PERL=C:\Perl522\perl ^
PYTHON_VER=27 DYNAMIC_PYTHON=yes PYTHON=C:\Python27-x64 ^
PYTHON3_VER=34 DYNAMIC_PYTHON3=yes PYTHON3=C:\Python34-x64 ^
LUA_VER=53 DYNAMIC_LUA=yes LUA=C:\Lua ^
TCL_VER=86 DYNAMIC_TCL=yes TCL=C:\Tcl ^
RUBY=C:\projects\ruby DYNAMIC_RUBY=yes RUBY_VER=22 RUBY_VER_LONG=2.2.0 ^
RUBY_INSTALL_NAME=msvcrt-ruby$(RUBY_API_VER) RUBY_PLATFORM=x64-mswin64_100 ^
RUBY_INC="/I $(RUBY)\include /I $(RUBY)\.ext\include\$(RUBY_PLATFORM)" ^
WINVER=0x500 ^
|| exit 1
:: Build CUI version
nmake -f Make_mvc2.mak CPU=AMD64 ^
GUI=no OLE=no DIRECTX=no ^
FEATURES=HUGE IME=yes MBYTE=yes ICONV=yes DEBUG=no ^
PERL_VER=522 DYNAMIC_PERL=yes PERL=C:\Perl522\perl ^
PYTHON_VER=27 DYNAMIC_PYTHON=yes PYTHON=C:\Python27-x64 ^
PYTHON3_VER=34 DYNAMIC_PYTHON3=yes PYTHON3=C:\Python34-x64 ^
LUA_VER=53 DYNAMIC_LUA=yes LUA=C:\Lua ^
TCL_VER=86 DYNAMIC_TCL=yes TCL=C:\Tcl ^
RUBY=C:\projects\ruby DYNAMIC_RUBY=yes RUBY_VER=22 RUBY_VER_LONG=2.2.0 ^
RUBY_INSTALL_NAME=msvcrt-ruby$(RUBY_API_VER) RUBY_PLATFORM=x64-mswin64_100 ^
RUBY_INC="/I $(RUBY)\include /I $(RUBY)\.ext\include\$(RUBY_PLATFORM)" ^
WINVER=0x500 ^
|| exit 1
:: Build translations
pushd po
nmake -f Make_mvc.mak GETTEXT_PATH=C:\cygwin\bin VIMRUNTIME=..\..\runtime install-all || exit 1
popd
@echo off
goto :eof