variables:
  UPSTREAM_REPO: monado/monado
  DEBIAN_VERSION: buster
  DEBIAN_TAG: '2019-03-19.0'
  DEBIAN_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/debian/$DEBIAN_VERSION:$DEBIAN_TAG
  DEBIAN_DEBS: build-essential git cmake meson ninja-build doxygen graphviz libeigen3-dev curl patch python3 pkg-config libx11-dev libxxf86vm-dev libxrandr-dev libxcb-randr0-dev libhidapi-dev libwayland-dev libvulkan-dev glslang-dev glslang-tools libglvnd-dev libgl1-mesa-dev ca-certificates
  DEBIAN_EXEC: 'bash .gitlab-ci/build-openxr-openhmd.sh'

include:
  - project: 'wayland/ci-templates'
    ref: c73dae8b84697ef18e2dbbf4fed7386d9652b0cd
    file: '/templates/debian.yml'

stages:
  - container_prep
  - build

container_prep:
  extends: .debian@container-ifnot-exists
  stage: container_prep

build-cmake:
  stage: build
  image: $DEBIAN_CONTAINER_IMAGE
  script:
  - mkdir build
  - pushd build
  - cmake -GNinja ..
  - ninja