1
0
Fork 0
mirror of https://github.com/anrieff/libcpuid synced 2024-11-20 23:01:51 +00:00
libcpuid/.github/workflows/build_openbsd.yml

60 lines
1.6 KiB
YAML
Raw Normal View History

2024-07-31 17:32:41 +00:00
name: Build (OpenBSD)
on:
push:
branches:
- '*'
pull_request:
branches:
- '*'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
2024-07-31 17:32:41 +00:00
jobs:
build_openbsd:
name: Build on ${{ matrix.box }}
runs-on: ubuntu-latest
strategy:
matrix:
box:
- generic/openbsd7
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Provision VM
2024-08-02 14:52:43 +00:00
uses: hummeltech/openbsd-vagrant-action@v2
2024-07-31 17:32:41 +00:00
with:
box: ${{ matrix.box }}
save_box_to_cache: true
- name: Install packages
run: sudo pkg_add -I cmake python3
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}
2024-07-31 17:32:41 +00:00
- name: Generate build system
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX="" -DLIBCPUID_ENABLE_TESTS=ON
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}
2024-07-31 17:32:41 +00:00
- name: Build
run: cmake --build build
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}
2024-07-31 17:32:41 +00:00
- name: Run cpuid_tool
run: ./build/cpuid_tool/cpuid_tool --save=- --all
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}
2024-07-31 17:32:41 +00:00
- name: Run tests
run: |
make -C build consistency
make -C build test-old
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}
2024-07-31 17:32:41 +00:00
- name: Install
run: cmake --install build
env:
DESTDIR: ${{ github.workspace }}/installdir
shell: /usr/local/bin/bash --noprofile --norc -euo pipefail {0}