image: registry.gitlab.gnome.org/gnome/gtk/gtk-3-24:v2

stages:
  - build

cache:
  paths:
    - _ccache/

fedora-autotools:
  stage: build
  script:
   - bash -x ./.gitlab-ci/test-docker-autotools.sh

fedora-meson:
  stage: build
  script:
   - bash -x ./.gitlab-ci/test-docker-meson.sh
  artifacts:
    when: always
    name: "gtk3-${CI_JOB_NAME}-${CI_COMMIT_REF_NAME}"
    paths:
      - "_build/meson-logs"

msys2-mingw32-meson:
  variables:
    MSYSTEM: "MINGW32"
    CHERE_INVOKING: "yes"
  stage: build
  tags:
    - win32
  script:
    - C:\msys64\usr\bin\pacman --noconfirm -Syyuu
    - C:\msys64\usr\bin\bash -lc "bash -x ./.gitlab-ci/test-msys2-meson.sh"
  artifacts:
    when: always
    name: "gtk3-%CI_JOB_NAME%-%CI_COMMIT_REF_NAME%"
    paths:
      - "_build/meson-logs"

msys2-mingw32-autotools:
  when: manual
  variables:
    MSYSTEM: "MINGW32"
    CHERE_INVOKING: "yes"
  stage: build
  tags:
    - win32
  script:
    - C:\msys64\usr\bin\pacman --noconfirm -Syyuu
    - C:\msys64\usr\bin\bash -lc "bash -x ./.gitlab-ci/test-msys2-autotools.sh"
