Print more information when an assertion fails in test suite (#649)
[platform/upstream/libffi.git] / .appveyor.yml
1 shallow_clone: true
2
3 # We're currently only testing libffi built with Microsoft's
4 # tools.
5 # This matrix should be expanded to include at least:
6 #  32- and 64-bit gcc/cygwin
7 #  32- and 64-bit gcc/mingw
8 #  32- and 64-bit clang/mingw
9 #  and perhaps more.
10
11 image: Visual Studio 2017
12 platform:
13   - x64
14   - x86
15   - arm
16   - arm64
17
18 configuration:
19   - Debug
20   - Release
21
22 environment:
23   global:
24     CYG_ROOT: C:/cygwin64
25     CYG_CACHE: C:/cygwin64/var/cache/setup
26     CYG_MIRROR: http://mirrors.kernel.org/sourceware/cygwin/
27     VSVER: 15
28   matrix:
29     - SHARED_ARG: "--enable-shared --disable-static"
30     - SHARED_ARG: "--enable-static --disable-shared"
31
32 install:
33   - ps: >-
34       If ($env:Platform -Match "x86") {
35           $env:VCVARS_PLATFORM="x86"
36           $env:BUILD="i686-pc-cygwin"
37           $env:HOST="i686-pc-cygwin"
38           $env:MSVCC="/cygdrive/c/projects/libffi/msvcc.sh"
39           $env:SRC_ARCHITECTURE="x86"
40         } ElseIf ($env:Platform -Match "arm64") {
41           $env:VCVARS_PLATFORM="x86_arm64"
42           $env:BUILD="i686-pc-cygwin"
43           $env:HOST="aarch64-w64-cygwin"
44           $env:MSVCC="/cygdrive/c/projects/libffi/msvcc.sh -marm64"
45           $env:SRC_ARCHITECTURE="aarch64"
46         } ElseIf ($env:Platform -Match "arm") {
47           $env:VCVARS_PLATFORM="x86_arm"
48           $env:BUILD="i686-pc-cygwin"
49           $env:HOST="arm-w32-cygwin"
50           $env:MSVCC="/cygdrive/c/projects/libffi/msvcc.sh -marm"
51           $env:SRC_ARCHITECTURE="arm"
52         } Else {
53           $env:VCVARS_PLATFORM="amd64"
54           $env:BUILD="x86_64-w64-cygwin"
55           $env:HOST="x86_64-w64-cygwin"
56           $env:MSVCC="/cygdrive/c/projects/libffi/msvcc.sh -m64"
57           $env:SRC_ARCHITECTURE="x86"
58       }
59       If ($env:Configuration -Match "Debug") {
60           $env:DEBUG_ARG="--enable-debug"
61         } Else {
62           $env:DEBUG_ARG="--disable-debug"
63       }
64   - 'appveyor DownloadFile https://cygwin.com/setup-x86_64.exe -FileName setup.exe'
65   - 'setup.exe -qgnNdO -R "%CYG_ROOT%" -s "%CYG_MIRROR%" -l "%CYG_CACHE%" -P dejagnu -P autoconf -P automake -P libtool'
66   - '%CYG_ROOT%/bin/bash -lc "cygcheck -dc cygwin"'
67   - echo call VsDevCmd to set VS150COMNTOOLS
68   - call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\Tools\VsDevCmd.bat"
69   - ps: $env:VSCOMNTOOLS=(Get-Content ("env:VS" + "$env:VSVER" + "0COMNTOOLS"))
70   - echo "Using Visual Studio %VSVER%.0 at %VSCOMNTOOLS%"
71   - call "%VSCOMNTOOLS%..\..\vc\Auxiliary\Build\vcvarsall.bat" %VCVARS_PLATFORM%
72
73 build_script:
74   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; ./autogen.sh)"
75   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; ./configure CC='%MSVCC%' CXX='%MSVCC%' LD='link' CPP='cl -nologo -EP' CXXCPP='cl -nologo -EP' CPPFLAGS='-DFFI_BUILDING_DLL' AR='/cygdrive/c/projects/libffi/.travis/ar-lib lib' NM='dumpbin -symbols' STRIP=':' --build=$BUILD --host=$HOST $DEBUG_ARG $SHARED_ARG)"
76   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; cp src/%SRC_ARCHITECTURE%/ffitarget.h include)"
77   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; make)"
78   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; cp $HOST/.libs/libffi.lib $HOST/testsuite/libffi-8.lib || true)"
79   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; cp `find . -name 'libffi-?.dll'` $HOST/testsuite/ || true)"
80   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; TERM=none make check RUNTESTFLAGS='-v -v -v -v --target '$HOST  DEJAGNU=$PWD/.appveyor/site.exp SITEDIR=$PWD/.appveyor)"
81
82
83 on_finish:
84   - c:\cygwin64\bin\sh -lc "(cd $OLDPWD; cat `find ./ -name libffi.log`)"