CI: Download Qt5 conditionally on Linux

Qt6 libraries are installed if the package is available on the system.
Uses the inverted condition to install Qt5 libraries to avoid
unnecessarily install both libraries.
This commit is contained in:
Norihiro Kamae
2023-05-13 16:44:45 -07:00
committed by Jim
parent 229236e821
commit 43c7742f8b
+4 -1
View File
@@ -37,7 +37,10 @@ install_qt5-deps() {
status "Install Qt5 dependencies"
trap "caught_error 'install_qt5-deps'" ERR
sudo apt-get install --no-install-recommends -y $@
_QT6_AVAILABLE="$(sudo apt-cache madison qt6-base-dev)"
if [ -z "${_QT6_AVAILABLE}" ]; then
sudo apt-get install --no-install-recommends -y $@
fi
}
install_qt6-deps() {