useful_scripts/install_software.sh

38 lines
1.3 KiB
Bash
Executable File

#!/bin/bash
sudo nala update
sudo nala install -y \
mpv `# for video playing` \
sxiv `# for pictures` \
strace `# for tracing` \
docker.io `# containers` \
# this is needed for pavucontrol working not under sudo only
for group in audio pulse-access pulse
do
sudo usermod -a -G $group $USER
done
# install ffmpeg with nvidia
if ! command -v ffmpeg &> /dev/null
then
git clone --depth 1 https://git.ffmpeg.org/ffmpeg.git ffmpeg/
git clone --depth 1 https://git.videolan.org/git/ffmpeg/nv-codec-headers.git
cd nv-codec-headers && sudo make install && cd -
sudo nala install -y build-essential yasm cmake libtool libc6 libc6-dev unzip wget libnuma1 libnuma-dev libasound2-dev
cd ffmpeg
./configure --enable-nonfree --enable-cuda-nvcc --enable-libnpp --enable-libxcb --enable-indev=alsa --enable-outdev=alsa --extra-cflags=-I/usr/lib/cuda/include --extra-ldflags=-L/usr/lib/cuda/lib64 --disable-static --enable-shared
make -j 8
sudo make install
cd -
rm -rf ffmpeg nv-codec-headers
fi
# install pet
if ! command -v pet &> /dev/null
then
wget https://github.com/knqyf263/pet/releases/download/v0.3.6/pet_0.3.6_linux_amd64.deb
sudo apt install -y ./pet_0.3.6_linux_amd64.deb
rm -f pet_0.3.6_linux_amd64.deb
fi