9 - target: i686-w64-mingw32
10 compiler_path: mingw32
11 openssl_path: /c/OpenSSL-Win32
12 mingw_prefix: mingw-w64-i686
14 - target: x86_64-w64-mingw32
15 compiler_path: mingw64
16 openssl_path: /c/OpenSSL-Win64
17 mingw_prefix: mingw-w64-x86_64
18 hardening: --disable-gcc-hardening
22 Function Execute-Command ($commandPath)
24 & $commandPath $args 2>&1
25 if ( $LastExitCode -ne 0 ) {
26 $host.SetShouldExit( $LastExitCode )
29 Function Execute-Bash ()
31 Execute-Command 'c:\msys64\usr\bin\bash' '-e' '-c' $args
33 Execute-Command "C:\msys64\usr\bin\pacman" -Sy --needed --noconfirm openssl-devel openssl libevent-devel libevent ${env:mingw_prefix}-libevent ${env:mingw_prefix}-zstd ;
37 if ($env:compiler -eq "mingw") {
38 $oldpath = ${env:Path} -split ';'
39 $buildpath = @("C:\msys64\${env:compiler_path}\bin", "C:\msys64\usr\bin") + $oldpath
40 $env:Path = @($buildpath) -join ';'
41 $env:build = @("${env:APPVEYOR_BUILD_FOLDER}", $env:target) -join '\'
42 Set-Location "${env:APPVEYOR_BUILD_FOLDER}"
43 Execute-Bash 'autoreconf -i'
45 Set-Location "${env:build}"
46 Execute-Bash "which ${env:target}-gcc"
47 Execute-Bash "${env:target}-gcc --version"
48 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}"
49 Execute-Bash "V=1 make -j2"
50 Execute-Bash "V=1 make -j2 install"
55 if ($env:compiler -eq "mingw") {
56 $oldpath = ${env:Path} -split ';'
57 $buildpath = @("C:\msys64\${env:compiler_path}\bin") + $oldpath
58 $env:Path = $buildpath -join ';'
59 Set-Location "${env:build}"
60 Execute-Bash "VERBOSE=1 make -j2 check"
65 if ($env:compiler -eq "mingw") {
66 $oldpath = ${env:Path} -split ';'
67 $buildpath = @("C:\msys64\usr\bin") + $oldpath
68 $env:Path = @($buildpath) -join ';'
69 Set-Location "${env:build}"
70 Execute-Bash "7z a logs.zip config.log || true"
71 Execute-Bash "7z a logs.zip test-suite.log || true"
72 Execute-Bash "appveyor PushArtifact logs.zip || true"
73 Execute-Bash "tail -1000 config.log || true"
74 Execute-Bash "cat test-suite.log || true"
76 - cmd: C:\Python27\python.exe %APPVEYOR_BUILD_FOLDER%\scripts\test\appveyor-irc-notify.py irc.oftc.net:6697 tor-ci failure