Files
winehelper/dependencies.sh
2026-01-20 16:53:29 +03:00

36 lines
1.4 KiB
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env bash
##### CHECK ROOT #####
if [[ $(id -u) -ne 0 ]] ; then
echo "Перезапустите скрипт $0 от root пользователя!"
exit 1
fi
##### MESSAGES FUNCTIONS #####
if [[ -t 0 ]] ; then
print_error () { printf "\E[31m%s Ошибка: $* %s\e[0m\n" ;}
else
print_error () { echo -e "Ошибка: $*" ;}
fi
fatal () {
print_error "$@ Аварийное завершение работы WineHelper!"
exit 1
}
##### CHECK AREPO (x86_64-i586) #####
apt-repo | grep -q "x86_64-i586" || fatal "Репозиторий x86_64-i586 не подключен. \
32-битные зависимости не будут установлены, а значит не будут работать и 32-битные \
windows приложения. Подробнее по ссылке: https://www.altlinux.org/Biarch"
##### UPDATE SYSTEM #####
apt-get update || fatal "Не удалось обновить список доступных пакетов,"
##### INSTALL DEPENDENCIES #####
# fonts-ttf-ms
apt-get install i586-{wine,glibc-core,libstdc++6,glibc-pthread,glibc-nss,\
libnm,libnss,libnss-mdns,libnsl1,libunwind,libunixODBC2,ocl-icd,libfreetype,\
libcups,libfontconfig1,libgnutls30,libGL,libEGL,libvulkan1,xorg-dri-swrast,\
xorg-dri-intel,xorg-dri-radeon} || fatal "Не удалось установить зависимости."