6 # Windows Server 2012 R2
15 - target: i686-w64-mingw32
16 compiler_path: mingw32
17 openssl_path: /c/OpenSSL-Win32
18 mingw_prefix: mingw-w64-i686
20 - target: x86_64-w64-mingw32
21 compiler_path: mingw64
22 openssl_path: /c/OpenSSL-Win64
23 mingw_prefix: mingw-w64-x86_64
24 hardening: --disable-gcc-hardening
28 Function Execute-Command ($commandPath)
30 & $commandPath $args 2>&1
31 if ( $LastExitCode -ne 0 ) {
32 $host.SetShouldExit( $LastExitCode )
35 Function Execute-Bash ()
37 Execute-Command 'c:\msys64\usr\bin\bash' '-e' '-c' $args
39 Execute-Command "C:\msys64\usr\bin\pacman" -Sy --needed --noconfirm openssl-devel openssl libevent-devel libevent ${env:mingw_prefix}-libevent ${env:mingw_prefix}-zstd ;
43 if ($env:compiler -eq "mingw") {
44 $oldpath = ${env:Path} -split ';'
45 $buildpath = @("C:\msys64\${env:compiler_path}\bin", "C:\msys64\usr\bin") + $oldpath
46 $env:Path = @($buildpath) -join ';'
47 $env:build = @("${env:APPVEYOR_BUILD_FOLDER}", $env:target) -join '\'
48 Set-Location "${env:APPVEYOR_BUILD_FOLDER}"
49 Execute-Bash 'autoreconf -i'
51 Set-Location "${env:build}"
52 Execute-Bash "which ${env:target}-gcc"
53 Execute-Bash "${env:target}-gcc --version"
54 Execute-Bash "../configure --prefix=/${env:compiler_path} --build=${env:target} --host=${env:target} --disable-asciidoc --enable-fatal-warnings --with-openssl-dir=${env:openssl_path} ${env:hardening}"
55 Execute-Bash "V=1 make -j2"
56 Execute-Bash "V=1 make -j2 install"
61 if ($env:compiler -eq "mingw") {
62 $oldpath = ${env:Path} -split ';'
63 $buildpath = @("C:\msys64\${env:compiler_path}\bin") + $oldpath
64 $env:Path = $buildpath -join ';'
65 Set-Location "${env:build}"
66 Execute-Bash "VERBOSE=1 make -j2 check"
71 if ($env:compiler -eq "mingw") {
72 $oldpath = ${env:Path} -split ';'
73 $buildpath = @("C:\msys64\usr\bin") + $oldpath
74 $env:Path = @($buildpath) -join ';'
75 Set-Location "${env:build}"
76 Execute-Bash "7z a logs.zip config.log || true"
77 Execute-Bash "7z a logs.zip test-suite.log || true"
78 Execute-Bash "appveyor PushArtifact logs.zip || true"
79 Execute-Bash "tail -1000 config.log || true"
80 Execute-Bash "cat test-suite.log || true"
82 - cmd: C:\Python27\python.exe %APPVEYOR_BUILD_FOLDER%\scripts\test\appveyor-irc-notify.py irc.oftc.net:6697 tor-ci failure