Merge branch 'main' into main #10
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: Ubuntu Build | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
BUILD_TYPE: Release | |
MTL_BUILD_DISABLE_PCAPNG: true | |
# GPRC_VERSION: v1.58.0 | |
PREFIX_DIR: /usr/local | |
DEBIAN_FRONTEND: noninteractive | |
permissions: | |
contents: read | |
jobs: | |
build: | |
timeout-minutes: 60 | |
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. | |
# You can convert this to a matrix build if you need cross-platform coverage. | |
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Harden Runner | |
uses: step-security/harden-runner@eb238b55efaa70779f274895e782ed17c84f2895 # v2.6.1 | |
with: | |
egress-policy: audit | |
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | |
- name: Setup | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y git gcc meson python3 python3-pip pkg-config libnuma-dev libjson-c-dev libpcap-dev libgtest-dev libsdl2-dev libsdl2-ttf-dev libssl-dev | |
sudo apt-get install -y cmake build-essential autoconf libtool pkg-config python3-pyelftools ninja-build | |
sudo apt-get install -y dpdk-dev | |
- name: Install IMTL | |
run: | | |
git clone --depth 1 https://github.com/OpenVisualCloud/Media-Transport-Library.git imtl | |
pushd imtl | |
./build.sh | |
popd | |
- uses: eWaterCycle/setup-grpc@f42b1ed4f95f2c8833e78d85a20cc717b6d9af7f # v5 | |
with: | |
grpc-version: 1.58.0 | |
# - name: Install gRPC | |
# run: | | |
# git clone --recurse-submodules -b ${GPRC_VERSION} --depth 1 --shallow-submodules https://github.com/grpc/grpc /tmp/grpc | |
# cmake -B /tmp/grpc/cmake/build -DgRPC_INSTALL=ON -DgRPC_BUILD_TESTS=OFF -DCMAKE_INSTALL_PREFIX=${PREFIX_DIR} /tmp/grpc/ | |
# cmake --build /tmp/grpc/cmake/build -j 4 | |
# sudo cmake --install /tmp/grpc/cmake/build | |
- name: Configure MCM | |
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. | |
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type | |
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
- name: Build MCM | |
# Build your program with the given configuration | |
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} | |