Skip to content

build: Fix Linux manifest file install #158

build: Fix Linux manifest file install

build: Fix Linux manifest file install #158

Workflow file for this run

# Copyright (c) 2024 The Khronos Group Inc.
# Copyright (c) 2023-2024 RasterGrid Kft.
# Copyright (c) 2023-2024 Valve Corporation
# Copyright (c) 2023-2024 LunarG, Inc.
#
# SPDX-License-Identifier: Apache-2.0
name: VKSC-PCU (Build/Tests)
# https://docs.github.com/en/actions/using-jobs/using-concurrency
concurrency:
# github.head_ref is only defined on pull_request
# Fallback to the run ID, which is guaranteed to be both unique and defined for the run.
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
on:
push:
branches-ignore:
- unified
pull_request:
branches:
- unified
permissions:
contents: read
jobs:
pre_build:
name: Pre-build tests
# Runner fixed to accelerate clang-format install, to omit installing a full-blown LLVM install
# with the likes of KyleMayes/install-llvm-action for. When oldest supported Ubuntu changes, so
# should the clang-format used.
runs-on: ubuntu-22.04
strategy:
fail-fast: false
steps:
- name: ${{ format('Checkout {0}', github.repository) }}
uses: actions/checkout@v4
- name: Check code formatting
uses: jidicula/[email protected]
with:
# Default clang-format in oldest supported Ubuntu (22.04), also available in 24.04
clang-format-version: '14'
- name: Check REUSE compliance
uses: fsfe/[email protected]
- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install clang-format
run: |
sudo apt update
sudo apt install clang-format
- name: Codegen identity
run: |
python3 scripts/update_deps.py --dir external --no-build
python3 scripts/generate_source.py external/Vulkan-Headers/registry/
git diff --exit-code
linux:
needs: pre_build
runs-on: ${{matrix.os}}
name: "linux (${{matrix.os}}, ${{matrix.config}})"
strategy:
fail-fast: false
matrix:
config: [ Debug, Release ]
os: [ ubuntu-22.04, ubuntu-24.04 ]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install CMake & Ninja
uses: lukka/get-cmake@latest
with:
cmakeVersion: 3.22.1
- name: Configure
run: |
cmake -S. -B build \
-G Ninja \
-D CMAKE_BUILD_TYPE=${{matrix.config}} \
-D BUILD_TESTS=ON \
-D UPDATE_DEPS=ON
- name: Build
run: cmake --build build/
- name: Test
run: ctest --test-dir build/ --output-on-failure
- name: Install
run: cmake --install build --prefix build/install
linux-sanitize:
needs: pre_build
runs-on: ${{matrix.os}}
name: "linux (${{matrix.sanitize}} sanitizer, ${{matrix.os}}, ${{matrix.config}})"
strategy:
fail-fast: false
matrix:
sanitize: [ ADDRESS, THREAD ]
config: [ Debug, Release ]
os: [ ubuntu-22.04, ubuntu-24.04 ]
exclude:
- config: Debug
sanitize: THREAD
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install CMake & Ninja
uses: lukka/get-cmake@latest
with:
cmakeVersion: 3.22.1
- name: Configure
run: |
cmake -S. -B build \
-G Ninja \
-D CMAKE_BUILD_TYPE=${{matrix.config}} \
-D BUILD_TESTS=ON \
-D UPDATE_DEPS=ON \
-D ENABLE_${{matrix.sanitize}}_SANITIZER=ON
- name: Build
run: cmake --build build/
- name: Test
run: ctest --test-dir build/ --output-on-failure
- name: Install
run: cmake --install build --prefix build/install
windows:
name: ${{ format('{0} ({1}), {2} ({3}, {4})', matrix.os, matrix.arch, matrix.toolset, matrix.config, matrix.runtime == 'DLL' && 'MD' || 'MT') }}
needs: pre_build
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ windows-2022 ]
arch: [ x64 ]
toolset: [ v143 ]
config: [ Debug, Release ]
runtime: [ DLL, '' ]
env:
# Better parallel MSBuild execution
UseMultiToolTask: 'true'
EnforceProcessCountAcrossBuilds: 'true'
MultiProcMaxCount: '3'
steps:
- name: ${{ format('Checkout {0}', github.repository) }}
uses: actions/checkout@v4
- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install CMake & Ninja
uses: lukka/get-cmake@latest
with:
cmakeVersion: 3.22.1
- name: Configure
run: |
cmake -S. -B build `
-G "Visual Studio 17 2022" `
-T ${{ matrix.toolset }} `
-A ${{ matrix.arch }} `
-D CMAKE_BUILD_TYPE=${{matrix.config}} `
-D CMAKE_MSVC_RUNTIME_LIBRARY=MultiThreaded$<$<CONFIG:Debug>:Debug>${{matrix.runtime}} `
-D BUILD_TESTS=${{ matrix.runtime == 'DLL' && 'ON' || 'OFF' }} `
-D UPDATE_DEPS=ON
- name: Build
run: cmake --build build/ --config ${{matrix.config}}
- name: Test
run: ctest --test-dir build/ --build-config ${{matrix.config}} --output-on-failure
- name: Install
run: cmake --install build --prefix build/install --config ${{matrix.config}}