2023-07-18 09:40:35 +03:00
|
|
|
packages_to_install() {
|
2023-07-18 10:49:19 +03:00
|
|
|
echo -n "libclang-dev,libgl1-mesa-dev,libxkbcommon-x11-0,libdbus-1-3"
|
|
|
|
|
2023-07-18 09:40:35 +03:00
|
|
|
case $QT in
|
|
|
|
5*)
|
|
|
|
echo -n ",libpulse-mainloop-glib0"
|
|
|
|
;;
|
|
|
|
*)
|
2023-07-18 10:49:19 +03:00
|
|
|
echo -n ""
|
2023-07-18 09:40:35 +03:00
|
|
|
;;
|
|
|
|
esac
|
2023-07-18 10:49:19 +03:00
|
|
|
|
2023-07-18 13:24:07 +03:00
|
|
|
echo -n ",gcc-$(get_g_version),g++-$(get_g_version)"
|
2023-07-18 10:49:19 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
verlte() {
|
|
|
|
printf '%s\n' "$1" "$2" | sort -C -V
|
|
|
|
}
|
|
|
|
|
|
|
|
verlt() {
|
|
|
|
! verlte "$2" "$1"
|
|
|
|
}
|
|
|
|
|
|
|
|
get_g_version() {
|
|
|
|
if verlt $QT "6.5.0"; then
|
|
|
|
echo -n "9"
|
|
|
|
else
|
|
|
|
echo -n "10"
|
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
switch_gcc_version() {
|
|
|
|
update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-$(get_g_version) 60 --slave /usr/bin/g++ g++ /usr/bin/g++-$(get_g_version)
|
2023-07-18 09:40:35 +03:00
|
|
|
}
|