environment:
  # We don't want to do identical comdat folding as it messes up the ability to
  # generate lossless backtraces in some cases. This is enabled by rustc by
  # default so pass a flag to disable it to ensure our tests work ok.
  RUSTFLAGS: -Clink-args=/OPT:NOICF

  matrix:
    - TARGET: x86_64-pc-windows-gnu
      MSYSTEM: MINGW64
      CPU: x86_64
    - TARGET: i686-pc-windows-gnu
      MSYSTEM: MINGW32
      CPU: i686

matrix:
  allow_failures:
    - TARGET: x86_64-pc-windows-gnu
    - TARGET: i686-pc-windows-gnu

install:
  - git submodule update --init --recursive
  - set PATH=c:\msys64\%MSYSTEM%\bin;c:\msys64\usr\bin;%PATH%
  - pacman --noconfirm -Syu mingw-w64-%CPU%-make
  - appveyor-retry appveyor DownloadFile https://win.rustup.rs/ -FileName rustup-init.exe
  - rustup-init.exe -y --default-host %TARGET% --default-toolchain nightly
  - set PATH=%PATH%;C:\Users\appveyor\.cargo\bin
  - rustc -vV
  - cargo -vV
build: false
test_script: sh ci\run.sh

branches:
  only:
    - master
