Forked from
The Tor Project / Core / Tor
1749 commits behind the upstream repository.
-
George Kadianakis authoredGeorge Kadianakis authored
.appveyor.yml 6.13 KiB
version: 1.0.{build}
clone_depth: 50
# Appveyor images are named after the Visual Studio version they contain.
# But we compile using MinGW, not Visual Studio.
# We use these images because they have different Windows versions.
image:
# Windows Server 2019
- Visual Studio 2019
environment:
compiler: mingw
matrix:
- target: i686-w64-mingw32
compiler_path: mingw32
mingw_prefix: mingw-w64-i686
hardening: --enable-all-bugs-are-fatal
- target: x86_64-w64-mingw32
compiler_path: mingw64
mingw_prefix: mingw-w64-x86_64
# hardening doesn't work with mingw-w64-x86_64-gcc, because it's gcc 8
hardening: --disable-gcc-hardening
matrix:
# Don't keep building failing jobs
fast_finish: true
# Skip the 32-bit Windows Server 2019 job, and the 64-bit Windows Server
# 2012 R2 job, to speed up the build.
# The environment variables must be listed without the 'environment' tag.
exclude:
- image: Visual Studio 2019
target: i686-w64-mingw32
compiler_path: mingw32
mingw_prefix: mingw-w64-i686
hardening: --enable-all-bugs-are-fatal
install:
- ps: >-
Function Execute-Command ($commandPath)
{
& $commandPath $args 2>&1
if ( $LastExitCode -ne 0 ) {
$host.SetShouldExit( $LastExitCode )
}
}
Function Execute-Bash ()
{
Execute-Command 'c:\msys64\usr\bin\bash' '-e' '-c' $args
}
<# mingw packages start with ${env:mingw_prefix}
# unprefixed packages are from MSYS2, which is like Cygwin. Avoid them.
#
# Use pacman --debug to show package downloads and install locations
#
# All installed library dlls must be copied to the test and app
# directories, before running tor's tests. (See below.)
#>
Execute-Command "C:\msys64\usr\bin\pacman" -Syu --verbose --noconfirm pacman ;
- ps: >-
Execute-Command "C:\msys64\usr\bin\pacman" -Sy --verbose --needed --noconfirm ${env:mingw_prefix}-libevent ${env:mingw_prefix}-openssl ${env:mingw_prefix}-pkg-config ${env:mingw_prefix}-xz ${env:mingw_prefix}-zstd ;
build_script:
- ps: >-
if ($env:compiler -eq "mingw") {
<# use the MSYS2 compiler and user binaries to build and install #>
$oldpath = ${env:Path} -split ';'
$buildpath = @("C:\msys64\${env:compiler_path}\bin", "C:\msys64\usr\bin") + $oldpath
$env:Path = @($buildpath) -join ';'