Skip to content

Cleanup crossplatform/compiler builds using CMakePresets.json #90

Cleanup crossplatform/compiler builds using CMakePresets.json

Cleanup crossplatform/compiler builds using CMakePresets.json #90

Workflow file for this run

name: x86-windows
on:
workflow_dispatch:
push:
branches: [ "master", "dev" ]
env:
BUILD_TYPE: Release
BUILD_DIR: build
PACKAGE_DIR: dab_radio_windows_x64
jobs:
skip_check:
continue-on-error: false
runs-on: ubuntu-22.04
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@v5
with:
concurrent_skipping: 'same_content'
cancel_others: 'true'
skip_after_successful_duplicate: 'true'
paths_ignore: '["**/README.md", "**/docs/**", "**/LICENSE.txt", "toolchains/arm/*", "toolchains/ubuntu/*", "toolchains/macos/*"]'
do_not_skip: '["workflow_dispatch", "schedule"]'
build:
needs: skip_check
if: needs.skip_check.outputs.should_skip != 'true'
runs-on: windows-2022
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
- name: Setup vcpkg with caching
uses: friendlyanon/setup-vcpkg@v1
with:
committish: c9140a3b500812ad3206317885860d9553b93f13
path: vcpkg
- name: Configure CMake
run: cmake . -B ${{env.BUILD_DIR}} --preset windows-msvc -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/vcpkg/scripts/buildsystems/vcpkg.cmake
- name: Build
run: cmake --build ${{env.BUILD_DIR}} --config ${{env.BUILD_TYPE}}
- name: Copy files
shell: bash
run: |
mkdir -p ${{env.PACKAGE_DIR}}
cp ${{env.BUILD_DIR}}/examples/*.exe ${{env.PACKAGE_DIR}}/
cp ${{env.BUILD_DIR}}/examples/*.dll ${{env.PACKAGE_DIR}}/
cp -rf res/ ${{env.PACKAGE_DIR}}/
cp README.md ${{env.PACKAGE_DIR}}/
- name: Upload files
uses: actions/upload-artifact@v3
with:
name: dab_radio_windows_x64
path: ${{github.workspace}}/${{env.PACKAGE_DIR}}