From 55ca146a82db058b5855db4982bca68decd9aa3e Mon Sep 17 00:00:00 2001 From: Joao Eriberto Mota Filho Date: Sun, 12 Sep 2021 10:38:06 -0300 Subject: [PATCH] Install missing obs-frontend-api.h --- .github/workflows/build-debian.yml | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-debian.yml b/.github/workflows/build-debian.yml index 5e1e1177..075a8aec 100644 --- a/.github/workflows/build-debian.yml +++ b/.github/workflows/build-debian.yml @@ -11,6 +11,24 @@ jobs: - uses: actions/checkout@v2 with: submodules: 'recursive' + - name: check_libobs_revision + run: | + sudo apt install libobs-dev + mkdir source + cd source + dpkg -l libobs-dev | tr -s " "| grep libobs | cut -d" " -f3 > libobs.rev + - name: install_frontend_header + run: | + [ -e /usr/include/obs/obs-frontend-api.h ] && { echo "ERROR: obs-frontend-api.h already in system. Maybe the package libobs-dev is installing it."; exit 1; } + cd source + LIBOBSREV=$(cat libobs.rev) + sudo apt install devscripts + dget -u http://archive.ubuntu.com/ubuntu/pool/universe/o/obs-studio/obs-studio_$LIBOBSREV.dsc + cd .. + sudo find -name obs-frontend-api.h -exec cp {} /usr/include/obs/ \; + egrep '#include ' /usr/include/obs/obs-frontend-api.h || { echo "ERROR: check if the sed commands are needed from now."; exit 1; } + sudo sed -i 's/#include /#include /' /usr/include/obs/obs-frontend-api.h + sudo sed -i 's/#include /#include /' /usr/include/obs/obs-frontend-api.h - name: create_tarball run: | cd .. @@ -20,8 +38,9 @@ jobs: cp -a CI/linux/debian . - name: install_dependencies run: | - sudo apt install cmake debhelper devscripts libcurl4-openssl-dev libobs-dev libxtst-dev qtbase5-dev libxss-dev - ls -l /usr/include/obs/ + # devscripts and libobs-dev are needed but they were already installed + # from check_libobs_revision and install_frontend_header sections. + sudo apt install cmake debhelper libcurl4-openssl-dev libxss-dev libxtst-dev qtbase5-dev - name: build run: | debuild --no-lintian --no-sign