diff --git a/scripts/Setup.sh b/scripts/Setup.sh index 9b0c21f..c98af3f 100755 --- a/scripts/Setup.sh +++ b/scripts/Setup.sh @@ -109,10 +109,16 @@ elif [ -x "$(command -v pacman)" ]; then i386="lib32-glibc" fi sudo pacman -S --needed --noconfirm axel imagemagick xxd python pyenv python-pip bc rsync curl zip unzip wget ffmpeg lvm2 fuse2 dosfstools e2fsprogs glibc exfatprogs util-linux parted bchunk base-devel icu pkgconf ffmpegthumbnailer $i386 2>&1 | tee -a "${LOG_FILE}" +# Or if user is on Gentoo-based system, do this instead +elif [ -x "$(command -v emerge)" ]; then + if [[ "$arch" = "x86_64" ]]; then + i386="glibc" + fi + sudo USE="lvm" emerge -q net-misc/axel media-gfx/imagemagick dev-util/xxd dev-lang/python dev-python/pip sys-devel/bc net-misc/rsync net-misc/curl app-arch/zip app-arch/unzip net-misc/wget media-video/ffmpeg sys-fs/lvm2 sys-fs/fuse sys-fs/dosfstools sys-fs/e2fsprogs sys-fs/exfatprogs sys-apps/util-linux sys-block/parted app-cdr/bchunk dev-libs/icu dev-util/pkgconf media-video/ffmpegthumbnailer app-arch/unrar $i386 2>&1 | tee -a "${LOG_FILE}" elif [ -n "$IN_NIX_SHELL" ]; then error_msg "Running in Nix environment - packages should be provided by flake and setup should not be run." else - error_msg "No supported package manager found (apt-get, dnf, pacman)." + error_msg "No supported package manager found (apt-get, dnf, pacman, emerge)." fi if [ $? -ne 0 ]; then @@ -134,4 +140,4 @@ spinner $PID "Setting up Python virtual environment and installing dependencies. echo echo -n "[✓] Setup completed successfully!" | tee -a "${LOG_FILE}" sleep 3 -echo| tee -a "${LOG_FILE}" \ No newline at end of file +echo| tee -a "${LOG_FILE}"