[ci] Fix clang-santisers job for GHA change
[xapian.git] / .appveyor.yml
blob3834616802701f79dd9f7d4951c041ba5fe60e54
1 skip_tags: true
2 # A full clone takes 30 seconds, depth 20 takes 5 seconds.
4 # Using "shallow_clone: true" downloads the commit as a ZIP file so you might
5 # think that would be quicker still, but actually it seems to take ~15 seconds,
6 # and then bootstrap fails due to there not being a ".git" directory.
7 clone_depth: 20
8 # Specify clone_folder so we can hard-code the Unix path equivalent below.
9 clone_folder: c:\projects\xapian
10 environment:
11   global:
12     AUTOMATED_TESTING: 1
13     CONFIGOPTS: --disable-documentation
14   matrix:
15   - platform: x86
16     APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
17     VCVARS_BAT: "\"C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Auxiliary\\Build\\vcvars32.bat\""
18   - platform: x64
19     APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
20     VCVARS_BAT: "\"C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\\VC\\Auxiliary\\Build\\vcvars64.bat\""
21 install:
22   - ps: $env:PATH="c:\msys64\usr\bin;$env:PATH"
23   - bash -c 'time ./bootstrap --fetch-url-command="curl --retry 5 --retry-connrefused -L" xapian-core'
24   - if defined VCVARS_BAT call %VCVARS_BAT%
25   - mkdir zlib
26   - cd zlib
27   - bash -c 'curl --retry 5 --retry-connrefused -L https://github.com/xapian/xapian-dev-deps/releases/download/current/zlib-1.2.13.tar.gz|tar --strip-components=1 -zxf -'
28   # Don't build zlib with -MD as it seems this flag needs to be used
29   # consistently across the build.
30   - sed -i 's/\(^CFLAGS  *= *-nologo \)-MD /\1/' win32/Makefile.msc
31   # Don't build zlib with a fixed base address on x64 as that gives linker
32   # warning LNK4281.
33   - if "%Platform%"=="x64" sed -i 's/-base:0x[0-9A-Fa-f]* //' win32/Makefile.msc
34   - nmake -nologo -f win32\Makefile.msc
35   - cd ..
36   # Fetch pre-built unicode-data.cc to avoid having to get working tclsh.
37   - curl --retry 5 --retry-connrefused https://oligarchy.co.uk/xapian/patches/unicode-data16.cc > xapian-core\unicode\unicode-data.cc
38   - ps: |
39       $env:AR="lib"
40       $env:CC="cl -nologo"
41       $env:CXX="c:/projects/xapian/xapian-core/compile cl -nologo"
42       $env:CPPFLAGS="-Ic:/projects/xapian/zlib"
43       # Standard C++ stack unwinding; assume extern "C" functions never throw.
44       $env:CXXFLAGS="-EHsc"
45       $env:LD="link"
46       $env:LDFLAGS="-Lc:/projects/xapian/zlib"
47       $env:NM="dumpbin"
48 build_script:
49   - bash -c 'time ./configure $CONFIGOPTS'
50   - bash -c 'time make -j2' < nul
51 test_script:
52   - bash -c 'time make check VERBOSE=1' < nul