matrix:
  linux_platform: ["debian10", "ubuntu2004"]
  osx_platform: ["macos", "macos_arm64"]
  bazel: [7.x, 8.x] 

tasks:
  verify_linux_targets:
    name: Verify linux build and test targets
    platform: ${{ linux_platform }}
    shell_commands:
    # X11 requires libx11-dev and a few other system packages, all in xorg-dev.
    # See https://www.glfw.org/docs/latest/compile.html#compile_deps
    - sudo apt-get update
    - sudo apt-get install xorg-dev -y
    bazel: ${{ bazel }}
    build_targets:
    - '@glfw//:glfw'
  verify_osx_targets:
    name: Verify osx build and test targets
    platform: ${{ osx_platform }}
    bazel: ${{ bazel }}
    build_targets:
    - '@glfw//:glfw'
    build_flags:
    - "--repo_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1"