]>
Commit | Line | Data |
---|---|---|
f67539c2 TL |
1 | # escape=` |
2 | # | |
3 | # Licensed under the Apache License, Version 2.0 (the "License"); | |
4 | # you may not use this file except in compliance with the License. | |
5 | # You may obtain a copy of the License at | |
6 | # | |
7 | # http://www.apache.org/licenses/LICENSE-2.0 | |
8 | # | |
9 | # Unless required by applicable law or agreed to in writing, software | |
10 | # distributed under the License is distributed on an "AS IS" BASIS, | |
11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
12 | # See the License for the specific language governing permissions and | |
13 | # limitations under the License. | |
14 | # | |
15 | ||
16 | FROM microsoft/dotnet-framework:4.7.1 | |
17 | ||
18 | # Restore the default Windows shell for correct batch processing below. | |
19 | SHELL ["cmd", "/S", "/C"] | |
20 | ||
21 | # Install Build Tools excluding workloads and components with known issues. | |
22 | ADD https://aka.ms/vs/15/release/vs_buildtools.exe C:\TEMP\vs_buildtools.exe | |
23 | RUN C:\TEMP\vs_buildtools.exe --quiet --wait --norestart --nocache ` | |
24 | --installPath C:\BuildTools ` | |
25 | --all ` | |
26 | --remove Microsoft.VisualStudio.Component.Windows10SDK.10240 ` | |
27 | --remove Microsoft.VisualStudio.Component.Windows10SDK.10586 ` | |
28 | --remove Microsoft.VisualStudio.Component.Windows10SDK.14393 ` | |
29 | --remove Microsoft.VisualStudio.Component.Windows81SDK ` | |
30 | || IF "%ERRORLEVEL%"=="3010" EXIT 0 | |
31 | RUN DEL C:\TEMP\vs_buildtools.exe | |
32 | ||
33 | # Install CMake | |
34 | ADD https://github.com/Kitware/CMake/releases/download/v3.13.4/cmake-3.13.4-win64-x64.msi C:\TEMP\cmake.msi | |
35 | RUN msiexec.exe /i C:\TEMP\cmake.msi /qn && ` | |
36 | SETX PATH "%PATH%;C:\Program Files\CMake\bin" && ` | |
37 | DEL C:\TEMP\cmake.msi | |
38 | ||
39 | # Install boost (for the thrift runtime library build) | |
40 | ADD https://boost.teeks99.com/bin/1.69.0/boost_1_69_0-msvc-14.1-64.exe C:\TEMP\boost.exe | |
41 | RUN C:\TEMP\boost.exe /DIR="C:\Libraries\boost_1_69_0" /SILENT && ` | |
42 | DEL C:\TEMP\boost.exe | |
43 | ||
44 | # Install chocolatey | |
45 | RUN @"%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe" ` | |
46 | -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command ` | |
47 | "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" ` | |
48 | && SETX PATH "%PATH%;%ALLUSERSPROFILE%\chocolatey\bin" | |
49 | ||
50 | # Install winflexbison (for the thrift compiler build) | |
51 | RUN choco install winflexbison3 -y | |
52 | ||
53 | # Install 7zip and curl (used by the libevent and zlib build scripts) | |
54 | RUN choco install 7zip curl -y | |
55 | ||
56 | # Install libevent | |
57 | COPY appveyor\build-libevent.bat C:\TEMP\build-libevent.bat | |
58 | ENV LIBEVENT_VERSION=2.1.8 | |
59 | ENV WIN3P=C:\TEMP\WIN3P | |
60 | RUN C:\BuildTools\Common7\Tools\VsDevCmd.bat -arch=amd64 && ` | |
61 | MKDIR C:\TEMP\WIN3P && ` | |
62 | C:\TEMP\build-libevent.bat && ` | |
63 | MKDIR C:\Libraries\libevent-%LIBEVENT_VERSION% && ` | |
64 | MOVE C:\TEMP\WIN3P\libevent-%LIBEVENT_VERSION%-stable\include C:\Libraries\libevent-%LIBEVENT_VERSION% && ` | |
65 | MOVE C:\TEMP\WIN3P\libevent-%LIBEVENT_VERSION%-stable\lib C:\Libraries\libevent-%LIBEVENT_VERSION% && ` | |
66 | RMDIR /S /Q C:\TEMP\WIN3P | |
67 | ||
68 | # Install zlib | |
69 | COPY appveyor\build-zlib.bat C:\TEMP\build-zlib.bat | |
70 | ENV ZLIB_VERSION=1.2.11 | |
71 | ENV WIN3P=C:\TEMP\WIN3P | |
72 | RUN C:\BuildTools\Common7\Tools\VsDevCmd.bat -arch=amd64 && ` | |
73 | MKDIR C:\TEMP\WIN3P && ` | |
74 | C:\TEMP\build-zlib.bat && ` | |
75 | MOVE C:\TEMP\WIN3P\zlib-inst C:\Libraries\zlib-%ZLIB_VERSION% && ` | |
76 | RMDIR /S /Q C:\TEMP\WIN3P | |
77 | ||
78 | # Install OpenSSL 1.1.0 | |
79 | ADD http://slproweb.com/download/Win64OpenSSL-1_1_0j.exe C:\TEMP\openssl.exe | |
80 | RUN C:\TEMP\openssl.exe /silent && ` | |
81 | DEL C:\TEMP\openssl.exe | |
82 | ||
83 | # Install java | |
84 | RUN choco install jdk8 -y | |
85 | ||
86 | # Install haskell | |
87 | RUN choco install ghc -y | |
88 | ||
89 | # Install python3 | |
90 | RUN choco install python3 -y | |
91 | ||
92 | # Install Adobe Flex 4.6 SDK and set FLEX_HOME so it can be found | |
93 | ADD http://download.macromedia.com/pub/flex/sdk/flex_sdk_4.6.zip C:\Adobe\Flex\SDK\4.6\SDK.zip | |
94 | RUN CD C:\Adobe\Flex\SDK\4.6 && ` | |
95 | 7z x SDK.zip && ` | |
96 | DEL SDK.zip && ` | |
97 | SETX FLEX_HOME "C:\Adobe\Flex\SDK\4.6" | |
98 | ||
99 | # Start developer command prompt with any other commands specified. | |
100 | ENTRYPOINT C:\BuildTools\Common7\Tools\VsDevCmd.bat -arch=amd64 && | |
101 | ||
102 | # Default to PowerShell if no other command specified. | |
103 | CMD ["powershell.exe", "-NoLogo", "-ExecutionPolicy", "Bypass"] |