Skip to content

Commit

Permalink
wip: new script
Browse files Browse the repository at this point in the history
  • Loading branch information
Julusian committed Jan 13, 2025
1 parent 822fbec commit 100ccf2
Showing 1 changed file with 50 additions and 19 deletions.
69 changes: 50 additions & 19 deletions .github/workflows/linux-system.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,41 +11,72 @@ jobs:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-22.04
- ubuntu-24.04
include:
- os: ubuntu-22.04
distribution: jammy
- os: ubuntu-24.04
distribution: noble

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4

- name: Setup environment
id: setup-env
run: |
sudo apt-get update
sudo ./tools/linux/install-dependencies
ln -s tools/linux/deb/ubuntu-${{ matrix.distribution }}/debian ./
BUILD_VERSION="1.2.3-dev+asda"
echo "BUILD_VERSION=$BUILD_VERSION" >> $GITHUB_OUTPUT
# install some needed tooling
sudo apt-get update
sudo apt-get -y install software-properties-common
sudo add-apt-repository ppa:casparcg/ppa
sudo apt-get install build-essential dpkg-dev debhelper
# Put something in the changelog
export DEBEMAIL="builds@casparcg.com"
export DEBFULLNAME="CasparCG Builds"
dch -v "1.2.3-dev+asda" --create -D ${{ matrix.distribution }} --package casparcg-server-beta "Build"
sudo apt-get -y install libboost-all-dev \
libavcodec-dev \
libavformat-dev \
libavdevice-dev \
libavutil-dev \
libavfilter-dev \
libswscale-dev \
libpostproc-dev \
libswresample-dev \
casparcg-cef-131-dev
# Install build dependencies
sudo apt-get build-dep .
# update the control file to reference the current cef version
CASPARCG_CEF_VER=$(dpkg-query -W -f='${Version}' casparcg-cef-131)
sed -i "s/@CASPARCG_CEF_VER@/${CASPARCG_CEF_VER}/" debian/control
# Download required packages
cd ..
apt download casparcg-cef-131
apt download casparcg-scanner
env:
CI: 1

- name: Run build
run: |
mkdir build
cd build
# Perform build
debuild -b -uc -us
env:
CI: 1

cmake ../src -DUSE_STATIC_BOOST=OFF -DUSE_SYSTEM_FFMPEG=ON -DUSE_SYSTEM_CEF=ON
make -j2
- name: Collect artifacts
run: |
mkdir -p dist
mv ../*.deb dist/
# TODO - collect a readme or something
zip -r "${{ steps.setup-env.outputs.BUILD_VERSION }}.zip" dist
env:
CI: 1

- uses: actions/upload-artifact@v4
with:
name: ${{ steps.setup-env.outputs.BUILD_VERSION }}
path: dist

# TODO - upload to website

0 comments on commit 100ccf2

Please sign in to comment.