From 910ab8024e961f5f6b58f20567f2b266a28bdea9 Mon Sep 17 00:00:00 2001 From: Joao Carreira Date: Tue, 6 Apr 2021 22:27:40 +0100 Subject: [PATCH] Add GitHub action to build code using cmake --- .github/workflows/build.yaml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/build.yaml diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..72ab300 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,31 @@ +name: Build and Test + +on: + push: + branches: + - devel + + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Install Dependencies + run: sudo apt-get install cmake qtbase5-dev libavcodec-dev libavformat-dev libavutil-dev libopencv-dev libopencv-video-dev libopencv-contrib-dev + + - name: Build CMake + uses: ashutoshvarma/action-cmake-build@v1 + with: + build-dir: ${{ runner.workspace }}/build + # will set the CC & CXX for cmake + cc: gcc + cxx: g++ + build-type: Release + # Extra options pass to cmake while configuring project + configure-options: -DBUILD_TESTS=ON -DUSE_WERROR=ON + run-test: true + #ctest-options: -R mytest + # install the build using cmake --install + install-build: true + # run build using '-j [parallel]' to use multiple threads to build + parallel: 14 \ No newline at end of file