Skip to content

Commit

Permalink
CI: Update build script for Ubuntu to require Ubuntu 24.04
Browse files Browse the repository at this point in the history
Also defaults to Qt6 and x86_64 builds, thus no toolchain file is
needed and no additional data in buildspec is needed either.
  • Loading branch information
PatTheMav committed Sep 14, 2024
1 parent bfa05ad commit 059dce5
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 35 deletions.
1 change: 0 additions & 1 deletion .github/scripts/.build.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,6 @@ build() {
local cmake_bin='/usr/bin/cmake'
cmake_args+=(
--preset ubuntu-ci
--toolchain ${project_root}/cmake/linux/toolchain-${target##*-}-gcc.cmake
-DENABLE_BROWSER:BOOL=ON
-DCEF_ROOT_DIR:PATH="${project_root}/.deps/cef_binary_${CEF_VERSION}_${target//ubuntu-/linux_}"
)
Expand Down
6 changes: 6 additions & 0 deletions .github/scripts/utils.zsh/check_ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ if [[ -f /etc/os-release ]] {
log_group
return 2
}

autoload -Uz is-at-least && if ! is-at-least 24.04 ${dist_version}; then
log_error "Not running on a recent-enough Ubuntu distribution. Aborting"
log_group
return 2
fi
} else {
log_error "Unable to determine local Linux distribution, but Ubuntu is required. Aborting"
log_group
Expand Down
27 changes: 3 additions & 24 deletions .github/scripts/utils.zsh/setup_ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,6 @@ local -a curl_opts=(--show-error --silent --location -O ${@})

pushd ${project_root}

typeset -g QT_VERSION
read -r QT_VERSION <<< \
"$(jq -r --arg target "${target}" \
'.platformConfig[$target] | { qtVersion } | join(" ")' \
${buildspec_file})"

log_group 'Installing obs-studio build dependencies...'

mkdir -p ${project_root}/.deps
Expand Down Expand Up @@ -90,21 +84,6 @@ sudo apt-get install -y --no-install-recommends \
libpulse-dev libsndio-dev libspeexdsp-dev libudev-dev libv4l-dev libva-dev libvlc-dev \
libpci-dev libdrm-dev \
nlohmann-json3-dev libwebsocketpp-dev libasio-dev libqrcodegencpp-dev \
libffmpeg-nvenc-dev librist-dev libsrt-openssl-dev

if [[ ${target##*-} == x86_64 ]] sudo apt-get install -y --no-install-recommends libvpl-dev libvpl2

local -a _qt_packages=()

if (( QT_VERSION == 6 )) {
_qt_packages+=(
qt6-base-dev
libqt6svg6-dev
qt6-base-private-dev
)
} else {
log_error "Unsupported Qt version '${QT_VERSION}' specified."
return 2
}

sudo apt-get install -y --no-install-recommends ${_qt_packages}
libffmpeg-nvenc-dev librist-dev libsrt-openssl-dev \
qt6-base-dev libqt6svg6-dev qt6-base-private-dev \
libvpl-dev libvpl2
10 changes: 0 additions & 10 deletions buildspec.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,5 @@
"hash": "ca59770e9f46b59d6bec6e7036a17a27d601a0a5a0a721fe8e03fea734ccf732"
}
},
"platformConfig": {
"ubuntu-x86_64": {
"qtVersion": 6,
"generator": "Ninja"
},
"ubuntu-aarch64": {
"qtVersion": 6,
"generator": "Ninja"
}
},
"name": "obs-studio"
}

0 comments on commit 059dce5

Please sign in to comment.