blob: d68ba27cc1ef7087dd960fcb40d92878d5e55045 [file] [log] [blame]
#!/usr/bin/env python3
# Copyright (c) 2020-2021 Valve Corporation
# Copyright (c) 2020-2021 LunarG, Inc.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# Author: Mark Lobodzinski <mark@lunarg.com>
name: CI Build
# Perform CI builds for pull requests targeting the master branch or any pushes to the repo.
on:
push:
pull_request:
branches:
- master
jobs:
code-format:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Source Code Format Testing",
os: ubuntu-latest,
cc: "gcc", cxx: "g++"
}
steps:
- name: Clone repository
uses: actions/checkout@v1
- name: Install build dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y python-pathlib
- name: Execute Source Code Format Checking Script
run: |
python3 scripts/check_code_format.py --target-refspec=origin/${{ github.base_ref }}
linux:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Ubuntu GCC Debug",
os: ubuntu-latest,
type: "debug",
build_dir: "build",
cc: "gcc", cxx: "g++"
}
- {
name: "Ubuntu Clang Debug",
os: ubuntu-latest,
type: "debug",
build_dir: "build",
cc: "clang", cxx: "clang++"
}
steps:
- name: Clone repository
uses: actions/checkout@v1
- name: Install build dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y libxkbcommon-dev libwayland-dev libmirclient-dev libxrandr-dev \
libx11-xcb-dev libxcb-keysyms1 libxcb-keysyms1-dev libxcb-ewmh-dev \
libxcb-randr0-dev python-pathlib cmake
- name: Build and Test Vulkan-ValidationLayers
run: |
python3 scripts/github_ci_win_linux.py --config ${{ matrix.config.type }}
gn:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Linux GN Debug Build ",
os: ubuntu-latest,
cc: "gcc", cxx: "g++"
}
steps:
- name: Clone repository
uses: actions/checkout@v1
- name: Install build dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y libxkbcommon-dev libwayland-dev libmirclient-dev libxrandr-dev \
libx11-xcb-dev libxcb-keysyms1 libxcb-keysyms1-dev libxcb-ewmh-dev \
libxcb-randr0-dev python-pathlib cmake
- name: Build Vulkan-ValidationLayers Using Ninja
run: |
python3 scripts/github_ci_gn.py
android:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Android armeabi-v8a",
os: ubuntu-latest,
abi: arm64-v8a,
ndk: r21d,
}
- {
name: "Android armeabi-v7a",
os: ubuntu-latest,
abi: armeabi-v7a,
ndk: r21d,
}
steps:
- name: Clone repository
uses: actions/checkout@v1
- name: Build ValidationLayers
run: |
python3 scripts/github_ci_android.py --abi ${{ matrix.config.abi }}