Skip to content

rpicam-vid: Update for camera sync algorithm #86

rpicam-vid: Update for camera sync algorithm

rpicam-vid: Update for camera sync algorithm #86

name: rpicam-app smoke tests
on:
pull_request:
branches: [ main ]
env:
GCC_COMPILER: "CC=/usr/bin/gcc CXX=/usr/bin/g++"
CLANG_COMPILER: "CC=/usr/bin/clang-13 CXX=/usr/bin/clang++-13"
LIBCAMERA_LKG_DIR: "/home/pi/libcamera_lkg"
jobs:
build-test:
runs-on: [ self-hosted ]
strategy:
matrix:
compiler: [ gcc, clang ]
build_type: [ release, debug ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
clean: true
- name: Configure meson
env:
COMPILER: "${{ matrix.compiler == 'gcc' && env.GCC_COMPILER || env.CLANG_COMPILER }}"
run: ${{env.COMPILER}} meson setup ${{github.workspace}}/build --pkg-config-path=${{env.LIBCAMERA_LKG_DIR}}/lib/aarch64-linux-gnu/pkgconfig/ -Dbuildtype=${{matrix.build_type}}
timeout-minutes: 5
- name: Build
run: ninja -C ${{github.workspace}}/build
timeout-minutes: 10
- name: Tar files
run: tar -cvf build-artifacts-${{matrix.compiler}}-${{matrix.build_type}}.tar -C ${{github.workspace}}/build .
- name: Upload build files
uses: actions/upload-artifact@v4
with:
name: build-artifacts-${{matrix.compiler}}-${{matrix.build_type}}
path: build-artifacts-${{matrix.compiler}}-${{matrix.build_type}}.tar
retention-days: 21
build-test-lite:
runs-on: [ self-hosted ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
clean: true
- name: Configure meson
run: meson setup ${{github.workspace}}/build --pkg-config-path=${{env.LIBCAMERA_LKG_DIR}}/lib/aarch64-linux-gnu/pkgconfig/ -Dbuildtype=release -Denable_drm='disabled' -Denable_egl='disabled' -Denable_qt='disabled' -Denable_opencv='disabled' -Denable_tflite='disabled' -Denable_libav='disabled'
timeout-minutes: 5
- name: Build
run: ninja -C ${{github.workspace}}/build
timeout-minutes: 10
- name: Tar files
run: tar -cvf build-artifacts-gcc-lite.tar -C ${{github.workspace}}/build .
- name: Upload build files
uses: actions/upload-artifact@v4
with:
name: build-artifacts-gcc-lite
path: build-artifacts-gcc-lite.tar
retention-days: 21
run-test:
runs-on: ${{matrix.camera}}
needs: build-test
strategy:
matrix:
camera: [ imx219, imx477, imx708, pi5-imx708-imx477 ]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
clean: true
- name: Create test output dir
run: mkdir -p ${{github.workspace}}/test_output
- name: Download build
uses: actions/download-artifact@v4
with:
name: build-artifacts-gcc-release
path: ${{github.workspace}}
- name: Untar files
run: tar -xvf build-artifacts-gcc-release.tar --one-top-level=build
- name: Print version string
run: ${{github.workspace}}/build/apps/rpicam-hello --version
- name: Print linkage info
run: ldd ${{github.workspace}}/build/apps/rpicam-hello | grep libcamera
- name: Test
run: ${{github.workspace}}/utils/test.py --exe-dir ${{github.workspace}}/build/apps/ --output-dir ${{github.workspace}}/test_output --json-dir ${{github.workspace}}/assets --post-process-libs ${{github.workspace}}/build/post_processing_stages/
timeout-minutes: 8
- name: Upload test output
if: ${{ failure() }}
uses: actions/upload-artifact@v4
with:
name: test-artifacts-${{matrix.camera}}
path: ${{github.workspace}}/test_output/
retention-days: 21