FW/Topology: fix num_packages() in -f exec mode (i.e. Windows) #433
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pull Request | |
on: | |
workflow_dispatch: | |
workflow_call: | |
push: | |
branches: [ main, socket-separation ] | |
env: | |
GIT_CONFIG_SYSTEM: /tmp/gitconfig | |
jobs: | |
build-linux-gcc: | |
runs-on: ubuntu-latest | |
container: debian:sid | |
steps: | |
- name: Install distro packages | |
run: | | |
DEBIAN_FRONTEND=noninteractive apt-get -y update | |
DEBIAN_FRONTEND=noninteractive apt-get -y install \ | |
bats \ | |
elfutils \ | |
file \ | |
git \ | |
libboost-dev \ | |
libeigen3-dev \ | |
libgtest-dev \ | |
libssl-dev \ | |
libzstd-dev \ | |
meson \ | |
ninja-build \ | |
python3-yaml \ | |
zlib1g-dev | |
- uses: actions/checkout@v2 | |
- name: setup Git | |
run: git config --system safe.directory '*' | |
- name: meson setup -Dbuildtype=debugoptimized | |
run: meson setup builddir -Dssl_link_type=dynamic -Dbuildtype=debugoptimized | |
- name: ninja build | |
run: ninja -C builddir | |
- name: ninja build unittests | |
run: ninja -C builddir unittests | |
- name: run unittests | |
run: | | |
./builddir/unittests \ | |
--gtest_filter=-LinuxThermalFixture.CurrentMachine_TestUsingSingletomTemperaturesOnCurrentMachine # this test doesn't execute properly in a github runner | |
- name: confirm opendcdiag runs | |
run: | | |
builddir/opendcdiag --version | |
builddir/opendcdiag --dump-cpu-info | |
- name: run selftests | |
run: | | |
ulimit -St 120 | |
SANDSTONE_BIN=builddir/opendcdiag bats -t bats/sanity-check | |
- name: run tests quickly | |
run: | | |
ulimit -St 120 | |
nproc=`nproc` | |
nproc=$((nproc > 4 ? 4 : nproc)) | |
builddir/opendcdiag --quick -n$nproc --retest-on-failure=0 -o - | |
build-linux-clang: | |
runs-on: ubuntu-latest | |
container: debian:sid | |
env: | |
CC: clang-16 | |
CXX: clang++-16 | |
steps: | |
- name: Install distro packages | |
run: | | |
DEBIAN_FRONTEND=noninteractive apt-get -y update | |
DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \ | |
bats \ | |
ca-certificates \ | |
${CC} \ | |
elfutils \ | |
file \ | |
git \ | |
libboost-dev \ | |
libeigen3-dev \ | |
libgtest-dev \ | |
libssl-dev \ | |
libzstd-dev \ | |
meson \ | |
ninja-build \ | |
python3-yaml \ | |
zlib1g-dev | |
- uses: actions/checkout@v2 | |
- name: setup Git | |
run: git config --system safe.directory '*' | |
- name: meson setup -Dbuildtype=debugoptimized | |
run: meson setup builddir -Dssl_link_type=dynamic -Dbuildtype=debugoptimized | |
- name: ninja build | |
run: ninja -C builddir | |
- name: confirm opendcdiag runs | |
run: | | |
builddir/opendcdiag --version | |
builddir/opendcdiag --dump-cpu-info | |
# Disabled: some negative tests fail to fail the way they're supposed to | |
# - name: run selftests | |
# run: | | |
# ulimit -St 120 | |
# SANDSTONE_BIN=builddir/opendcdiag bats -t bats/sanity-check | |
- name: run tests quickly | |
run: | | |
ulimit -St 120 | |
nproc=`nproc` | |
nproc=$((nproc > 4 ? 4 : nproc)) | |
builddir/opendcdiag --quick -n$nproc --retest-on-failure=0 -o - | |
build-windows: | |
runs-on: ubuntu-latest | |
container: fedora:38 | |
env: | |
WINEDEBUG: fixme-all,-dbghelp_stabs | |
WINEPREFIX: /tmp/wine_root | |
WINEPATH: d:/bin | |
steps: | |
- name: Install distro packages | |
run: | | |
dnf install --setopt=install_weak_deps=False -y \ | |
cmake \ | |
git \ | |
meson \ | |
mingw64-boost \ | |
mingw64-eigen3 \ | |
mingw64-gcc-c++ \ | |
mingw64-pixman \ | |
mingw64-pkg-config \ | |
mingw64-winpthreads-static \ | |
mingw64-zlib \ | |
mingw64-zstd \ | |
perl | |
- uses: actions/checkout@v2 | |
- name: setup Git | |
run: git config --system safe.directory '*' | |
- name: meson setup | |
run: meson setup builddir-windows-cross -Dbuildtype=release --cross-file meson-cross-win32.ini | |
- name: ninja build | |
run: ninja -C builddir-windows-cross | |
- name: install Wine | |
run: | | |
dnf install --setopt=install_weak_deps=False -y \ | |
bats \ | |
elfutils \ | |
python3-pyyaml \ | |
wine | |
# Create drive D: at MinGW's sysroot | |
winecfg | |
rpm -ql mingw64-zlib | sed -n '/bin\/zlib1.dll/s///p' | \ | |
xargs -rtI@ ln -s @ $WINEPREFIX/dosdevices/d: | |
# Disable the GUI debugger | |
wine reg add 'HKEY_LOCAL_MACHINE\Software\Wine\winedbg' /v ShowCrashDialog /t REG_DWORD /d 00000000 | |
- name: confirm Wine works | |
run: | | |
wine cmd /c ver | |
wine builddir-windows-cross/opendcdiag.exe --version | |
wine builddir-windows-cross/opendcdiag.exe --dump-cpu-info | |
- name: run selftests | |
run: SANDSTONE_BIN=builddir-windows-cross/opendcdiag.exe bats -t bats/sanity-check | |
- name: run tests quickly | |
run: | | |
ulimit -St 120 | |
nproc=`nproc` | |
nproc=$((nproc > 4 ? 4 : nproc)) | |
wine builddir-windows-cross/opendcdiag.exe --quick --retest-on-failure=0 -n$nproc -o - |