Update c-cpp.yml #5
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: C/C++ CI Ubuntu 22.04 | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
submodules: 'recursive' # Ensure submodules are checked out | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y cmake build-essential git pkg-config libgtk-3-dev \ | |
libavcodec-dev libavformat-dev libswscale-dev libv4l-dev libxvidcore-dev libx264-dev \ | |
libjpeg-dev libpng-dev libtiff-dev gfortran openexr libatlas-base-dev python3-dev \ | |
python3-numpy libtbb2 libtbb-dev libsqlite3-dev g++ g++-multilib doxygen zlib1g-dev \ | |
libunwind-dev libsnappy-dev liblz4-dev elfutils libdw-dev libiberty-dev | |
- name: Configure and Build | |
run: | | |
mkdir build && cd build | |
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=../install .. | |
make -j$(nproc) | |
make install | |
- name: List install directory contents | |
run: | | |
ls -lah ../install | |
- name: Package | |
run: | | |
cd ../install | |
tar -czvf dynamorio-${{ github.sha }}.tar.gz * | |
- name: Upload Artifacts | |
uses: actions/upload-artifact@v2 | |
with: | |
name: dynamorio-${{ github.run_id }} | |
path: ../install/dynamorio-${{ github.sha }}.tar.gz |