image: ralfjung/opam-ci:opam2

stages:
  - build

variables:
  CPU_CORES: "10"

.template: &template
  stage: build
  tags:
  - fp
  script:
  - git clone https://gitlab.mpi-sws.org/iris/ci.git ci -b opam2
  - ci/buildjob
  cache:
    key: "$CI_JOB_NAME"
    paths:
    - _opam/
  only:
  - master@iris/stdpp
  - /^ci/@iris/stdpp
  except:
  - triggers
  - schedules
  - api

## Build jobs

build-coq.dev:
  <<: *template
  variables:
    OPAM_PINS: "coq version dev"
    MANGLE_NAMES: "1"
    CI_COQCHK: "1"

build-coq.8.13.2:
  <<: *template
  variables:
    OPAM_PINS: "coq version 8.13.2"
    DENY_WARNINGS: "1"
    OPAM_PKG: "1"
    DOC_DIR: "coqdoc@center.mpi-sws.org:stdpp"
  tags:
  - fp-timing

build-coq.8.12.2:
  <<: *template
  variables:
    OPAM_PINS: "coq version 8.12.2"
    DENY_WARNINGS: "1"

build-coq.8.11.2:
  <<: *template
  variables:
    OPAM_PINS: "coq version 8.11.2"

build-coq.8.10.2:
  <<: *template
  variables:
    OPAM_PINS: "coq version 8.10.2"
