-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Build and test | ||
on: | ||
push: | ||
branches: [ "wip_actions" ] | ||
pull_request: | ||
branches: [ "wip_actions" ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-24.04 | ||
container: archlinux:base-devel | ||
steps: | ||
- name: install-dependencies | ||
run: | | ||
sudo pacman -Syu --noconfirm cmake git git-lfs boost boost-libs doxygen nodejs node-gyp gtest yarn ffmpeg nlohmann-json | ||
sudo corepack enable | ||
- uses: actions/checkout@v4 | ||
with: | ||
path: ./src | ||
submodules: recursive | ||
- name: install-js-dependencies | ||
run: | | ||
cd src && yarn | ||
- name: build-js | ||
run: | | ||
cd src && yarn run bundle | ||
- name: build-debug | ||
run: | | ||
cmake -DCMAKE_BUILD_TYPE=Debug -DENABLE_JS=OFF -DXCMAKE_CLANG_TIDY=OFF -DXCMAKE_SYSTEM_GTEST=ON -DXCMAKE_DOXYGEN_WERROR=OFF -DCMAKE_INSTALL_PREFIX=inst -Bbuild src | ||
make -C build install -j$(nproc) | ||
- name: build-release | ||
run: | | ||
rm -rf build inst | ||
cmake -DCMAKE_BUILD_TYPE=Release -DENABLE_JS=OFF -DXCMAKE_PACKAGING=On -DXCMAKE_CLANG_TIDY=OFF -DXCMAKE_SYSTEM_GTEST=ON -DXCMAKE_DOXYGEN_WERROR=Off -DCMAKE_INSTALL_PREFIX=inst -Bbuild src | ||
make -C build install package -j$(nproc) | ||
tar tf build/*.tar.gz | ||
# Check package contents. | ||
tar tf build/*.tar.gz | grep -qE '^spectral-live-video-streamer/bin/live-video-streamer-server$' | ||
tar tf build/*.tar.gz | grep -qE '^SpectralLiveVideoStreamer/share/spectral-video-streamer/demo-client/index[.]html$' | ||
tar tf build/*.tar.gz | grep -qE '^SpectralLiveVideoStreamer/share/spectral-video-streamer/client/live-video-streamer-client[.]js$' | ||
tar tf build/*.tar.gz | grep -qE '^SpectralLiveVideoStreamer/share/spectral-video-streamer/client/live-video-streamer-client[.]d[.]ts$' | ||
! tar tf build/*.tar.gz | grep -qE '([.]map|/asset-manifest[.]json)$' |