From ae66af419f00919fbf7529e4b81aa516afc32446 Mon Sep 17 00:00:00 2001 From: stornic56 <71296607+stornic56@users.noreply.github.com> Date: Thu, 17 Sep 2026 15:52:45 -0500 Subject: [PATCH 1/4] update openvino + neo + igc - Real update capability (derived INSTALL_DIR, replace policy, stable symlink) - Mesa >= 25.2 transition fix on Debian 13 (mesa-va-drivers/vdpau) - Robustness: SIGPIPE fixes, dead repair code, EOF stdin, unbound vars, trap cleanup (modules + --install), strict booleans, set -euo pipefail in deps/ - Ubuntu 22.04 doc alignment - Validated end-to-end on Debian 13 + Arc B580 (clinfo 26.31, vainfo iHD OK)" --- README.md | 41 ++-- core/openvino_logic.sh | 45 +++-- deps/install_openvino_dependencies.sh | 258 +++++++++++++------------- main.sh | 84 +++++---- modules/setup_debian.sh | 56 +++--- modules/setup_fedora.sh | 2 +- modules/setup_ubuntu.sh | 54 +++--- 7 files changed, 282 insertions(+), 258 deletions(-) diff --git a/README.md b/README.md index 94c0b2e..e8734ff 100644 --- a/README.md +++ b/README.md @@ -4,10 +4,11 @@ This project repository provides a comprehensive automated installation and conf ## Supported Operating Systems -* Debian 13 -* Ubuntu 24.04 -* Ubuntu 26.04 -* Fedora 43 +* Debian 13 +* Ubuntu 22.04 +* Ubuntu 24.04 +* Ubuntu 26.04 +* Fedora 43 --- @@ -16,7 +17,9 @@ This project repository provides a comprehensive automated installation and conf The installer scripts are designed to be executed as a root user (`sudo`). Ensure all necessary system dependencies (such as `git`, `wget`, and the respective package managers like `dpkg`/`dnf`) exist before execution. ### Setup & Clone Repository + First, clone the repository from GitHub: + ```bash # 1. Clone the installer repository git clone https://github.com/stornic56/openvino-runtime-simple-installer @@ -27,7 +30,9 @@ chmod +x main.sh ``` ### Execution + Execute the primary installation script using elevated privileges (root access is mandatory): + ```bash sudo ./main.sh ``` @@ -37,19 +42,21 @@ sudo ./main.sh The execution of `main.sh` automatically handles OS detection and conditionally installs components based on hardware presence, ensuring a fully configured inference pipeline: **Core Runtime & Libraries:** -* **OpenVINO Toolkit 2026.0:** The complete runtime package is downloaded from the official OpenVINO repository (`https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.0/linux`) and installed under `/opt/intel/openvino_2026`. It is the same version used in llama.cpp in its builds. -* **System Dependencies:** Required libraries, including `cmake`, Python 3 (with version-specific dependencies like `libpython3.13` for Debian 13 or `libpython3.13` for Ubuntu 26.04), GCC compilers (`g++`), NumPy bindings, and standard development tools are installed via system package managers (`apt`/`dnf`). + +* **OpenVINO Toolkit 2026.3.1:** The complete runtime package is downloaded from the official OpenVINO repository (`https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.3.1/linux`) and installed under `/opt/intel/openvino_2026`. It is the same version used in llama.cpp in its builds. +* **System Dependencies:** Required libraries, including `cmake`, Python 3 (with version-specific dependencies like `libpython3.13` for Debian 13 or `libpython3.13` for Ubuntu 26.04), GCC compilers (`g++`), NumPy bindings, and standard development tools are installed via system package managers (`apt`/`dnf`). **Hardware Acceleration & Drivers (NEO):** -* **Intel Compute Runtime NEO:** If an Intel GPU is detected, the respective module script installs critical proprietary drivers: - * `intel-igc-core`: Graphics Compiler core components. - * `intel-igc-opencl`: OpenCL interface libraries for graphics compilation. - * `intel-ocloc`/`libze-intel-gpu1`: Compute Runtime interfaces and GPU acceleration layers (OpenCL/oneAPI). - * **Multimedia Support:** Installation of `mesa-va-drivers`, `vainfo`, and related packages to ensure Video Acceleration API support, crucial for media inference tasks. + +* **Intel Compute Runtime NEO (26.31.39395.13):** If an Intel GPU is detected, the respective module script installs critical proprietary drivers: + * `intel-igc-core` (2.40.13): Graphics Compiler core components. + * `intel-igc-opencl` (2.40.13): OpenCL interface libraries for graphics compilation. + * `intel-ocloc`/`libze-intel-gpu1`: Compute Runtime interfaces and GPU acceleration layers (OpenCL/oneAPI). + * **Multimedia Support:** Installation of `mesa-va-drivers`, `vainfo`, and related packages to ensure Video Acceleration API support, crucial for media inference tasks. **Environment Configuration:** -* User permissions are configured by adding the executing user (`$SUDO_USER`) to the system groups `render` and `video` to allow proper GPU access post-installation. +* User permissions are configured by adding the executing user (`$SUDO_USER`) to the system groups `render` and `video` to allow proper GPU access post-installation. ## After Installation @@ -66,8 +73,10 @@ clinfo | grep -i "device name" 4. Check video acceleration vainfo ``` -## Note: + +## Note + Users should reference the following official projects: -- Llamacpp: [Official Repository Link](https://github.com/ggml-org/llama.cpp) and [OpenvinoBackend](https://github.com/ggml-org/llama.cpp/blob/master/docs/backend/OPENVINO.md) -- OpenVino Toolkit: [Docs](https://docs.openvino.ai/2026/get-started/install-openvino/install-openvino-archive-linux.html) and [github](https://github.com/openvinotoolkit/openvino) -- Intel NEO Drivers: [Intel Compute Runtime](https://github.com/intel/compute-runtime) +* Llamacpp: [Official Repository Link](https://github.com/ggml-org/llama.cpp) and [OpenvinoBackend](https://github.com/ggml-org/llama.cpp/blob/master/docs/backend/OPENVINO.md) +* OpenVino Toolkit: [Docs](https://docs.openvino.ai/2026/get-started/install-openvino/install-openvino-archive-linux.html) and [github](https://github.com/openvinotoolkit/openvino) +* Intel NEO Drivers: [Intel Compute Runtime](https://github.com/intel/compute-runtime) diff --git a/core/openvino_logic.sh b/core/openvino_logic.sh index 0f0a5d4..ca0e278 100644 --- a/core/openvino_logic.sh +++ b/core/openvino_logic.sh @@ -17,30 +17,45 @@ if [ "$1" = "--install" ]; then exit 1 fi - # Clean up any previous installation before proceeding - if [ -d "/opt/intel/openvino_2026.0" ]; then - print_warning "An existing OpenVINO installation was found. Removing it..." - rm -rf "/opt/intel/openvino_2026.0" - fi - if [ -L "/opt/intel/openvino_2026" ]; then - rm -f "/opt/intel/openvino_2026" - fi + # Derive destination from version (official doc pattern: year.patch) + # e.g. openvino_toolkit_ubuntu24__x86_64.tgz -> /opt/intel/openvino_ + VERSION_FULL="$(echo "$FILENAME" | cut -d_ -f4)" + case "$VERSION_FULL" in + 20[0-9][0-9].*) ;; # valid version format, continue + *) + print_error "Could not derive version from: $FILENAME" + exit 1 + ;; + esac + INSTALL_DIR="/opt/intel/openvino_$(echo "$VERSION_FULL" | cut -d. -f1-3)" + # Replace policy (updates): remove ANY previous 2026 install and the previous symlink. + # Known limitation: the previous install is deleted BEFORE extracting; if the tar + # failed afterwards, the system would be left without OpenVINO. Acceptable because + # the SHA256 was already verified during the download step. + if ls -d /opt/intel/openvino_2026.* >/dev/null 2>&1; then + print_warning "An existing OpenVINO installation was found. Replacing it..." + fi + rm -rf /opt/intel/openvino_2026 # remove previous symlink OR real directory (rm -rf does not follow symlinks) + rm -rf /opt/intel/openvino_2026.* # ANY previous 2026 install + mkdir -p /opt/intel + + DIRNAME="${FILENAME%.tgz}" # known before tar (enables trap cleanup) + trap 'rm -rf "$DIRNAME"' EXIT print_substep "Unzipping $FILENAME..." tar -xf "$FILENAME" - # The name of the extracted folder matches the name of the tarball without the .tgz extension - DIRNAME="${FILENAME%.tgz}" if [ ! -d "$DIRNAME" ]; then # guess the real name - DIRNAME=$(tar -tf "$FILENAME" | head -1 | cut -d/ -f1) + TAR_LIST=$(tar -tf "$FILENAME") + DIRNAME="${TAR_LIST%%$'\n'*}" # first entry (no pipe, no SIGPIPE) + DIRNAME="${DIRNAME%%/*}" fi - print_substep "Moving $DIRNAME a /opt/intel/openvino_2026.0..." - mkdir -p /opt/intel - mv "$DIRNAME" "/opt/intel/openvino_2026.0" + print_substep "Moving $DIRNAME a $INSTALL_DIR..." + mv "$DIRNAME" "$INSTALL_DIR" print_substep "Create symbolic link /opt/intel/openvino_2026..." - ln -sf /opt/intel/openvino_2026.0 /opt/intel/openvino_2026 + ln -s "$INSTALL_DIR" /opt/intel/openvino_2026 exit 0 fi diff --git a/deps/install_openvino_dependencies.sh b/deps/install_openvino_dependencies.sh index 268da71..c635db2 100644 --- a/deps/install_openvino_dependencies.sh +++ b/deps/install_openvino_dependencies.sh @@ -6,7 +6,7 @@ # Modified by stornic56 (2026) to add support for Debian 13 (Trixie), Ubuntu 26.04, # and Python 3.13 dependencies. Also ensures dnf is used on Fedora. -set -e +set -euo pipefail #=================================================================================================== # Option parsing @@ -26,24 +26,24 @@ keepcache= selftest= while :; do - case $1 in - -h|-\?|--help) - echo "Options:" - echo " -y non-interactive run (off)" - echo " -n dry-run, assume no (off)" - echo " -c= install component , can be repeated (${all_comp[*]})" - echo " -e add extra repositories (RHEL 7, 8, 9) (off)" - echo " -p print package list and exit (off)" - exit - ;; - -y) interactive= ;; - -n) dry=yes ;; - -c=?*) comp+=("${1#*=}") ;; - -e) extra=yes ;; - -p) print=yes ;; - --selftest) selftest=yes ;; - --keepcache) keepcache=yes ;; - *) break ;; + case "${1:-}" in + -h | -\? | --help) + echo "Options:" + echo " -y non-interactive run (off)" + echo " -n dry-run, assume no (off)" + echo " -c= install component , can be repeated (${all_comp[*]})" + echo " -e add extra repositories (RHEL 7, 8, 9) (off)" + echo " -p print package list and exit (off)" + exit + ;; + -y) interactive= ;; + -n) dry=yes ;; + -c=?*) comp+=("${1#*=}") ;; + -e) extra=yes ;; + -p) print=yes ;; + --selftest) selftest=yes ;; + --keepcache) keepcache=yes ;; + *) break ;; esac shift done @@ -56,22 +56,22 @@ fi #=================================================================================================== # Selftest -if [ -n "$selftest" ] ; then +if [ -n "$selftest" ]; then for image in centos:7 centos:8 rhel:8 rhel:9.1 \ - almalinux:8.7 amazonlinux:2 \ - fedora:34 fedora:35 fedora:36 fedora:37 fedora:38 \ - opensuse/leap:15.3 \ - raspbian:9 debian:9 ubuntu:18.04 \ - raspbian:10 debian:10 ubuntu:20.04 ubuntu:20.10 ubuntu:21.04 \ - raspbian:11 debian:11 ubuntu:21.10 ubuntu:22.04 \ - raspbian:12 debian:12 debian:13 ubuntu:22.10 ubuntu:23.04 ubuntu:24.04; do - for opt in "-h" "-p" "-e -p" "-n" "-n -e" "-y" "-y -e" ; do + almalinux:8.7 amazonlinux:2 \ + fedora:34 fedora:35 fedora:36 fedora:37 fedora:38 \ + opensuse/leap:15.3 \ + raspbian:9 debian:9 ubuntu:18.04 \ + raspbian:10 debian:10 ubuntu:20.04 ubuntu:20.10 ubuntu:21.04 \ + raspbian:11 debian:11 ubuntu:21.10 ubuntu:22.04 \ + raspbian:12 debian:12 debian:13 ubuntu:22.10 ubuntu:23.04 ubuntu:24.04; do + for opt in "-h" "-p" "-e -p" "-n" "-n -e" "-y" "-y -e"; do echo "||" echo "|| Test $image / '$opt'" echo "||" - SCRIPT_DIR="$( cd "$( dirname "$(realpath "${BASH_SOURCE:-$0}")" )" >/dev/null 2>&1 && pwd )" + SCRIPT_DIR="$(cd "$(dirname "$(realpath "${BASH_SOURCE:-$0}")")" >/dev/null 2>&1 && pwd)" docker run -it --rm \ - --volume "${SCRIPT_DIR}":/scripts:ro,Z \ + --volume "${SCRIPT_DIR}":/scripts:ro,Z \ --volume yum-cache:/var/cache/yum \ --volume apt-cache:/var/cache/apt/archives \ -e DEBIAN_FRONTEND=noninteractive \ @@ -87,9 +87,9 @@ if [ -n "$selftest" ] ; then echo "||" echo "|| Test ubuntu:26.04 / '$opt'" echo "||" - SCRIPT_DIR="$( cd "$( dirname "$(realpath "${BASH_SOURCE:-$0}")" )" >/dev/null 2>&1 && pwd )" + SCRIPT_DIR="$(cd "$(dirname "$(realpath "${BASH_SOURCE:-$0}")")" >/dev/null 2>&1 && pwd)" docker run -it --rm \ - --volume "${SCRIPT_DIR}":/scripts:ro,Z \ + --volume "${SCRIPT_DIR}":/scripts:ro,Z \ --volume yum-cache:/var/cache/yum \ --volume apt-cache:/var/cache/apt/archives \ -e DEBIAN_FRONTEND=noninteractive \ @@ -108,32 +108,40 @@ fi #=================================================================================================== # OS detection -if [ "$os" == "auto" ] ; then - # shellcheck source=/dev/null - os=$( . /etc/os-release ; echo "${ID}${VERSION_ID}" ) - if [[ "$os" =~ "rhel8".* ]] ; then - os="rhel8" +if [ "$os" == "auto" ]; then + os="" + if [ -f /etc/os-release ]; then + os=$( + . /etc/os-release + echo "${ID:-}${VERSION_ID:-}" + ) + fi + if [[ "$os" =~ "rhel8".* ]]; then + os="rhel8" fi case $os in - centos7|centos8|centos9|\ - rhel8|rhel9.1|rhel9.2|rhel9.3|rhel9.4|\ - opencloudos8.5|opencloudos8.6|opencloudos8.8|opencloudos9.0|opencloudos9.2|\ - tencentos3.1|tencentos3.2|tencentos3.3|tencentos4.0|tencentos4.2|\ - anolis8.6|anolis8.8|\ - openEuler20.03|openEuler22.03|openEuler23.03|openEuler24.03|\ - almalinux8.7|almalinux8.8|almalinux9.2|almalinux9.3|almalinux9.4|\ - amzn2|amzn2022|amzn2023|\ - ol8.7|ol8.8|ol9.2|ol9.3|ol9.4|\ - rocky8.7|rocky8.8|rocky9.2|rocky9.3|rocky9.4|\ - fedora29|fedora30|fedora31|fedora32|fedora33|fedora34|fedora35|fedora36|\ - fedora37|fedora38|fedora39|fedora40|fedora41|\ - fedora42|fedora43|fedora44|fedora*|\ - opensuse-leap15.3|\ - raspbian9|debian9|ubuntu18.04|\ - raspbian10|debian10|ubuntu20.04|ubuntu20.10|ubuntu21.04|\ - raspbian11|debian11|ubuntu21.10|ubuntu22.04|\ - raspbian12|debian12|debian13|ubuntu22.10|ubuntu23.04|ubuntu23.10|ubuntu24.04|ubuntu26.04) [ -z "$print" ] && echo "Detected OS: ${os}" ;; - *) echo "Unsupported OS: ${os:-detection failed}" >&2 ; exit 1 ;; + centos7 | centos8 | centos9 | \ + rhel8 | rhel9.1 | rhel9.2 | rhel9.3 | rhel9.4 | \ + opencloudos8.5 | opencloudos8.6 | opencloudos8.8 | opencloudos9.0 | opencloudos9.2 | \ + tencentos3.1 | tencentos3.2 | tencentos3.3 | tencentos4.0 | tencentos4.2 | \ + anolis8.6 | anolis8.8 | \ + openEuler20.03 | openEuler22.03 | openEuler23.03 | openEuler24.03 | \ + almalinux8.7 | almalinux8.8 | almalinux9.2 | almalinux9.3 | almalinux9.4 | \ + amzn2 | amzn2022 | amzn2023 | \ + ol8.7 | ol8.8 | ol9.2 | ol9.3 | ol9.4 | \ + rocky8.7 | rocky8.8 | rocky9.2 | rocky9.3 | rocky9.4 | \ + fedora29 | fedora30 | fedora31 | fedora32 | fedora33 | fedora34 | fedora35 | fedora36 | \ + fedora37 | fedora38 | fedora39 | fedora40 | fedora41 | \ + fedora42 | fedora43 | fedora44 | fedora* | \ + opensuse-leap15.3 | \ + raspbian9 | debian9 | ubuntu18.04 | \ + raspbian10 | debian10 | ubuntu20.04 | ubuntu20.10 | ubuntu21.04 | \ + raspbian11 | debian11 | ubuntu21.10 | ubuntu22.04 | \ + raspbian12 | debian12 | debian13 | ubuntu22.10 | ubuntu23.04 | ubuntu23.10 | ubuntu24.04 | ubuntu26.04) [ -z "$print" ] && echo "Detected OS: ${os}" ;; + *) + echo "Unsupported OS: ${os:-detection failed}" >&2 + exit 1 + ;; esac fi @@ -147,15 +155,15 @@ if [ "$os" == "raspbian9" ] || [ "$os" == "debian9" ]; then pkgs_python=() pkgs_dev=(pkg-config g++ gcc libc6-dev make sudo) -elif [ "$os" == "ubuntu18.04" ] ; then +elif [ "$os" == "ubuntu18.04" ]; then pkgs_gpu=(ocl-icd-libopencl1) pkgs_python=(python3.8 libpython3.8 python3.8-venv python3-pip) pkgs_dev=(cmake pkg-config g++ gcc libc6-dev make sudo) -elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || \ - [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || \ - [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || \ - [ "$os" == "debian13" ] || [ "$os" == "ubuntu26.04" ]; then +elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || + [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || + [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || + [ "$os" == "debian13" ] || [ "$os" == "ubuntu26.04" ]; then pkgs_gpu=(ocl-icd-libopencl1) pkgs_python=(python3 python3-venv python3-pip) @@ -165,11 +173,11 @@ elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "debian10" ] || [ "$os" == "raspbi pkgs_python+=(libpython3.7) elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "ubuntu20.10" ] || [ "$os" == "ubuntu21.04" ]; then pkgs_python+=(libpython3.8) - elif [ "$os" == "ubuntu21.10" ] || \ - [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ]; then + elif [ "$os" == "ubuntu21.10" ] || + [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ]; then pkgs_python+=(libpython3.9) - elif [ "$os" == "ubuntu22.04" ] || [ "$os" == "ubuntu22.10" ] || \ - [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ]; then + elif [ "$os" == "ubuntu22.04" ] || [ "$os" == "ubuntu22.10" ] || + [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ]; then pkgs_python+=(libpython3.10) elif [ "$os" == "ubuntu23.04" ]; then pkgs_python+=(libpython3.11) @@ -182,29 +190,29 @@ elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "debian10" ] || [ "$os" == "raspbi fi elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "rhel8" ] || - [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || - [ "$os" == "opencloudos8.5" ] || [ "$os" == "opencloudos8.6" ] || [ "$os" == "opencloudos8.8" ] || - [ "$os" == "opencloudos9.0" ] || [ "$os" == "opencloudos9.2" ] || - [ "$os" == "tencentos3.1" ] || [ "$os" == "tencentos3.2" ] || [ "$os" == "tencentos3.3" ] || - [ "$os" == "tencentos4.0" ] || [ "$os" == "tencentos4.2" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || - [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ] ; then + [ "$os" == "rhel8" ] || + [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || + [ "$os" == "opencloudos8.5" ] || [ "$os" == "opencloudos8.6" ] || [ "$os" == "opencloudos8.8" ] || + [ "$os" == "opencloudos9.0" ] || [ "$os" == "opencloudos9.2" ] || + [ "$os" == "tencentos3.1" ] || [ "$os" == "tencentos3.2" ] || [ "$os" == "tencentos3.3" ] || + [ "$os" == "tencentos4.0" ] || [ "$os" == "tencentos4.2" ] || + [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || + [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || + [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || + [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || + [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || + [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || + [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || + [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || + [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || + [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || + [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || + [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || + [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ]; then arch=$(uname -m) - if [ "$os" == "amzn2" ] ; then + if [ "$os" == "amzn2" ]; then amazon-linux-extras install epel python3.8 fi @@ -212,42 +220,42 @@ elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] pkgs_python=() pkgs_dev=(gcc gcc-c++ make glibc libstdc++ libgcc cmake3 sudo) - if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ] ; then + if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ]; then pkgs_dev+=(pkgconfig) else pkgs_dev+=(pkgconf-pkg-config) fi if [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] ; then + [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || + [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || + [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || + [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || + [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || + [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || + [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || + [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || + [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || + [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || + [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ] || + [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || + [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ]; then pkgs_python+=(python3 python3-pip) fi - if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ] ; then + if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ]; then pkgs_gpu+=("ocl-icd.$arch") extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm") - elif [ "$os" == "rhel8" ] ; then + elif [ "$os" == "rhel8" ]; then pkgs_gpu+=("http://vault.centos.org/centos/8-stream/AppStream/$arch/os/Packages/ocl-icd-2.2.12-1.el8.$arch.rpm") pkgs_python+=(python38 python38-pip) extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm") - elif [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] ; then + elif [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ]; then pkgs_gpu+=("https://mirror.stream.centos.org/9-stream/AppStream/$arch/os/Packages/ocl-icd-2.2.13-4.el9.$arch.rpm") pkgs_python+=(python3 python3-pip) extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm") fi -elif [ "$os" == "opensuse-leap15.3" ] ; then +elif [ "$os" == "opensuse-leap15.3" ]; then pkgs_gpu=(libOpenCL1) pkgs_python=(python39-base python39 python39-venv python39-pip) pkgs_dev=(cmake pkg-config gcc-c++ gcc make sudo) @@ -260,13 +268,13 @@ fi # Gather packages and print list pkgs=() -for comp in "${comp[@]}" ; do +for comp in "${comp[@]}"; do var="pkgs_${comp}[@]" pkgs+=("${!var}") done if [ ${#pkgs[@]} -eq 0 ]; then - if [ -n "$print" ] ; then + if [ -n "$print" ]; then echo "No packages to install" >&2 exit 1 else @@ -275,7 +283,7 @@ if [ ${#pkgs[@]} -eq 0 ]; then fi fi -if [ -n "$print" ] ; then +if [ -n "$print" ]; then echo "${pkgs[*]}" exit 0 fi @@ -292,9 +300,9 @@ fi iopt= if [ "$os" == "debian9" ] || [ "$os" == "raspbian9" ] || [ "$os" == "ubuntu18.04" ] || - [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || [ "$os" == "ubuntu20.04" ] || [ "$os" == "ubuntu20.10" ] || [ "$os" == "ubuntu21.04" ] || - [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || - [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || [ "$os" == "debian13" ] || [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu23.10" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "ubuntu26.04" ] ; then + [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || [ "$os" == "ubuntu20.04" ] || [ "$os" == "ubuntu20.10" ] || [ "$os" == "ubuntu21.04" ] || + [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || + [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || [ "$os" == "debian13" ] || [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu23.10" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "ubuntu26.04" ]; then [ -z "$interactive" ] && iopt="-y" [ -n "$dry" ] && iopt="--dry-run" @@ -303,21 +311,21 @@ if [ "$os" == "debian9" ] || [ "$os" == "raspbian9" ] || [ "$os" == "ubuntu18.04 apt-get update && apt-get install --no-install-recommends "$iopt" "${pkgs[@]}" elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "rhel8" ] || - [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || - [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ] ; then + [ "$os" == "rhel8" ] || + [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || + [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || + [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || + [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || + [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || + [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || + [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || + [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || + [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || + [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || + [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || + [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || + [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || + [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ]; then # Usar dnf en Fedora moderna, yum en el resto if [[ "$os" == fedora* ]]; then @@ -333,7 +341,7 @@ elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] $PKGCMD install ${iopt:+$iopt} "${pkgs[@]}" -elif [ "$os" == "opensuse-leap15.3" ] ; then +elif [ "$os" == "opensuse-leap15.3" ]; then [ -z "$interactive" ] && iopt="-y" [ -n "$dry" ] && iopt="--dry-run" diff --git a/main.sh b/main.sh index a64e405..78374a3 100644 --- a/main.sh +++ b/main.sh @@ -45,26 +45,27 @@ print_substep "System detected: $OS_ID $VERSION_ID" # Prefix mapping case "$OS_ID" in - debian) - PREFIX="ubuntu24" # Tested and working on Debian 13 - ;; - ubuntu) - case "$VERSION_ID" in - 22.04) PREFIX="ubuntu22" ;; - 24.04|26.04) PREFIX="ubuntu24" ;; - *) - print_error "Unsupported Ubuntu version: $VERSION_ID" - exit 1 - ;; - esac - ;; - fedora) - PREFIX="rhel8" - ;; +debian) + PREFIX="ubuntu24" # Tested and working on Debian 13 + ;; +ubuntu) + case "$VERSION_ID" in + 22.04) PREFIX="ubuntu22" ;; + 24.04) PREFIX="ubuntu24" ;; + 26.04) PREFIX="ubuntu26" ;; *) - print_error "Unsupported distribution: $OS_ID" + print_error "Unsupported Ubuntu version: $VERSION_ID" exit 1 ;; + esac + ;; +fedora) + PREFIX="rhel8" + ;; +*) + print_error "Unsupported distribution: $OS_ID" + exit 1 + ;; esac # ------------------------------------------------------------------------------ @@ -72,38 +73,43 @@ esac # ------------------------------------------------------------------------------ print_step "2. Detecting Intel GPU..." -if GPU_LINE=$(lspci -nn | grep -i "vga\|3d\|display" | grep -i "intel" | head -1); then +LSPCI_INTEL=$(lspci -nn 2>/dev/null | grep -i "vga\|3d\|display" | grep -i "intel" || true) # lspci missing -> empty -> prompt (documented degradation) +GPU_LINE="${LSPCI_INTEL%%$'\n'*}" +if [ -n "$GPU_LINE" ]; then GPU_NAME=$(echo "$GPU_LINE" | awk -F': ' '{print $2}') print_substep "Intel GPU detected: $GPU_NAME" GPU_PRESENT=true else print_warning "No Intel GPU was detected." GPU_PRESENT=false - read -p "Do you want to continue the installation WITHOUT GPU support? [y/n]: " response + read -r -p "Do you want to continue the installation WITHOUT GPU support? [y/n]: " response || { + print_error "No interactive input available (stdin closed). Installation cancelled." + exit 1 + } case "$response" in - [yY]*) ;; - *) - print_error "Installation cancelled by the user." - exit 0 - ;; + [yY]*) ;; + *) + print_error "Installation cancelled by the user." + exit 0 + ;; esac fi # ------------------------------------------------------------------------------ # 3. Install NEO (only if there is a GPU) # ------------------------------------------------------------------------------ -if $GPU_PRESENT; then +if [ "$GPU_PRESENT" = true ]; then print_step "3. Installing GPU drivers (Intel Compute Runtime NEO)..." case "$OS_ID" in - debian) - bash "$MODULES_DIR/setup_debian.sh" - ;; - ubuntu) - bash "$MODULES_DIR/setup_ubuntu.sh" - ;; - fedora) - bash "$MODULES_DIR/setup_fedora.sh" - ;; + debian) + bash "$MODULES_DIR/setup_debian.sh" + ;; + ubuntu) + bash "$MODULES_DIR/setup_ubuntu.sh" + ;; + fedora) + bash "$MODULES_DIR/setup_fedora.sh" + ;; esac else print_step "3. Skipping NEO driver installation (no Intel GPU)." @@ -113,8 +119,8 @@ fi # 4. Download OpenVINO Runtime # ------------------------------------------------------------------------------ print_step "4. Downloading OpenVINO Runtime package..." -BASE_URL="https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.0/linux" -VERSION="2026.0.0.20965.c6d6a13a886" +BASE_URL="https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.3.1/linux" +VERSION="2026.3.1.22476.56d9685302d" FILENAME="openvino_toolkit_${PREFIX}_${VERSION}_x86_64.tgz" URL="$BASE_URL/$FILENAME" @@ -143,8 +149,8 @@ bash "$CORE_DIR/openvino_logic.sh" --install "$FILENAME" print_step "Installation completed successfully!" # installed version -if [ -f "/opt/intel/openvino_2026.0/runtime/version.txt" ]; then - echo "Version: $(cat /opt/intel/openvino_2026.0/runtime/version.txt)" +if [ -f "/opt/intel/openvino_2026/runtime/version.txt" ]; then + echo "Version: $(cat /opt/intel/openvino_2026/runtime/version.txt)" else echo "Version: could not be determined" fi @@ -155,7 +161,7 @@ echo " source /opt/intel/openvino_2026/setupvars.sh" echo "" echo "----------------------------------------------------------------------" -if $GPU_PRESENT; then +if [ "$GPU_PRESENT" = true ]; then echo "IMPORTANT NOTES:" echo "1. Restart your session (or system) for the group changes (render, video) to take effect and for you to be able to use the GPU." echo "2. Check the OpenCL status with: clinfo" diff --git a/modules/setup_debian.sh b/modules/setup_debian.sh index f295d86..3337ffd 100644 --- a/modules/setup_debian.sh +++ b/modules/setup_debian.sh @@ -11,9 +11,9 @@ print_step "Debian Module – Drivers and Multimedia" print_substep "Ensuring non-free components in sources.list..." SOURCES_FILE="/etc/apt/sources.list" if [ -f "$SOURCES_FILE" ]; then - sudo sed -i 's/^\(deb.*trixie.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" - sudo sed -i 's/^\(deb.*trixie-security.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" - sudo sed -i 's/^\(deb.*trixie-updates.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" + sed -i 's/^\(deb.*trixie.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" + sed -i 's/^\(deb.*trixie-security.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" + sed -i 's/^\(deb.*trixie-updates.*main\)[^#]*/\1 contrib non-free non-free-firmware/' "$SOURCES_FILE" fi if [ -f /etc/apt/sources.list.d/debian.sources ]; then @@ -27,7 +27,7 @@ print_substep "Installing graphics and diagnostic packages..." apt-get install -y \ python3-numpy libmfx-gen1.2 libvpl2 libegl-mesa0 libegl1-mesa-dev libgbm1 \ libgl1-mesa-dri libglapi-mesa libgles2-mesa-dev libglx-mesa0 libxatracker2 \ - mesa-va-drivers mesa-vdpau-drivers vainfo clinfo nvtop ocl-icd-libopencl1 + mesa-libgallium vainfo clinfo nvtop ocl-icd-libopencl1 print_substep "Installing Intel video driver..." if apt-get install -y intel-media-va-driver-non-free; then @@ -41,15 +41,16 @@ fi print_substep "Downloading and installing NEO…" TEMP_DIR=$(mktemp -d) cd "$TEMP_DIR" +trap 'rm -rf "$TEMP_DIR"' EXIT # Hashes SHA256 declare -A NEO_HASHES=( - ["intel-igc-core-2_2.34.4+21428_amd64.deb"]="1150de9f1b8c06aab0bf6e619a6c02ed4cd0c7b4135752ae74c82c8f8fb7acb2" - ["intel-igc-opencl-2_2.34.4+21428_amd64.deb"]="f36cb8a6899353c61cc7261b650f287f4a652acadaad859103bdfc51f93b6e8a" - ["intel-ocloc_26.18.38308.1-0_amd64.deb"]="74b98d91a92d59c487e4938175284e57d5a84ec35d9997a9d65fa4db3f51b96b" - ["intel-opencl-icd_26.18.38308.1-0_amd64.deb"]="b2d0c924e56b3f9e5837774d68b0c67461b8633035d93ca18b1a8e3e5ead15fa" + ["intel-igc-core-2_2.40.13+22418_amd64.deb"]="ebd795e9fddf303a9b24b7f04545d8ddd9ad1f85b3d0cb1166476fab24da6d44" + ["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]="4f990874efc11c3f6091a663b08aef576c4af592dcd8f12e116f8c2fc92d34d9" + ["intel-ocloc_26.31.39395.13-0_amd64.deb"]="12c5e61ed1dca5cbf38494e280abf88100a451580d57c44f601a17d9727e465e" + ["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]="5a9c9e8fdca8a2f9e22754b1a4618c7babf21d7c3ab3503c680005007c7a8c44" ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.18.38308.1-0_amd64.deb"]="12b8254e6d3415c32cee9cd13943030b991d91212445c79fe1cc27176a72eca4" + ["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]="1722943f81b576b9bb8d61016464208f48ce533dc3bf24ad39605293115cc289" ) download_and_verify() { @@ -64,32 +65,21 @@ download_and_verify() { fi } -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.34.4/intel-igc-core-2_2.34.4+21428_amd64.deb" \ - "intel-igc-core-2_2.34.4+21428_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.34.4+21428_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.34.4/intel-igc-opencl-2_2.34.4+21428_amd64.deb" \ - "intel-igc-opencl-2_2.34.4+21428_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.34.4+21428_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/intel-ocloc_26.18.38308.1-0_amd64.deb" \ - "intel-ocloc_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.18.38308.1-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/intel-opencl-icd_26.18.38308.1-0_amd64.deb" \ - "intel-opencl-icd_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.18.38308.1-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/libigdgmm12_22.10.0_amd64.deb" \ +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-core-2_2.40.13+22418_amd64.deb" \ + "intel-igc-core-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.40.13+22418_amd64.deb"]}" +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-opencl-2_2.40.13+22418_amd64.deb" \ + "intel-igc-opencl-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-ocloc_26.31.39395.13-0_amd64.deb" \ + "intel-ocloc_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-opencl-icd_26.31.39395.13-0_amd64.deb" \ + "intel-opencl-icd_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libigdgmm12_22.10.0_amd64.deb" \ "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/libze-intel-gpu1_26.18.38308.1-0_amd64.deb" \ - "libze-intel-gpu1_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.18.38308.1-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libze-intel-gpu1_26.31.39395.13-0_amd64.deb" \ + "libze-intel-gpu1_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]}" print_substep "Instalando paquetes deb..." -dpkg -i libigdgmm12_22.10.0_amd64.deb - -dpkg -i intel-igc-core-2_2.34.4+21428_amd64.deb - -dpkg -i intel-igc-opencl-2_2.34.4+21428_amd64.deb - -dpkg -i intel-ocloc_26.18.38308.1-0_amd64.deb - -dpkg -i libze-intel-gpu1_26.18.38308.1-0_amd64.deb - -dpkg -i intel-opencl-icd_26.18.38308.1-0_amd64.deb -apt-get install -f -y +apt-get install -y ./*.deb cd / rm -rf "$TEMP_DIR" @@ -100,6 +90,6 @@ if [ -n "${SUDO_USER:-}" ]; then usermod -a -G render,video "$SUDO_USER" else # root - current_user=$(logname 2>/dev/null || echo "$USER") + current_user="${SUDO_USER:-$(logname 2>/dev/null || id -un)}" usermod -a -G render,video "$current_user" fi diff --git a/modules/setup_fedora.sh b/modules/setup_fedora.sh index 274c0fc..05ee490 100644 --- a/modules/setup_fedora.sh +++ b/modules/setup_fedora.sh @@ -23,6 +23,6 @@ print_substep "Adding user to render and video groups (if they exist)..." if [ -n "${SUDO_USER:-}" ]; then usermod -a -G render,video "$SUDO_USER" else - current_user=$(logname 2>/dev/null || echo "$USER") + current_user="${SUDO_USER:-$(logname 2>/dev/null || id -un)}" usermod -a -G render,video "$current_user" fi diff --git a/modules/setup_ubuntu.sh b/modules/setup_ubuntu.sh index cbd189e..18b3488 100644 --- a/modules/setup_ubuntu.sh +++ b/modules/setup_ubuntu.sh @@ -12,6 +12,12 @@ apt-get update # ---- 2. Paquetes multimedia y diagnóstico ---- print_substep "Installing graphics and diagnostic packages..." +# TODO (H0 watch-out): Debian 13 required dropping mesa-va-drivers AND mesa-vdpau-drivers +# in favor of mesa-libgallium (Mesa >= 25.2 moved the gallium VA-API and VDPAU drivers into +# mesa-libgallium, which Breaks both old names < 25.2.8-3; no amd64 version >= 25.2.8-3 +# exists in trixie nor backports -- see setup_debian.sh). Ubuntu 24.04 is not affected +# (mesa 24.x, real packages). Ubuntu 26.04 may be affected if it ships Mesa >= 25.2 (same +# transition) -- change only with evidence. apt-get install -y \ python3-numpy libmfx-gen1.2 libvpl2 libegl-mesa0 libegl1-mesa-dev libgbm1 \ libgl1-mesa-dri libglapi-mesa libgles2-mesa-dev libglx-mesa0 libxatracker2 \ @@ -24,14 +30,15 @@ apt-get install -y intel-media-va-driver-non-free print_substep "Downloading and installing NEO…" TEMP_DIR=$(mktemp -d) cd "$TEMP_DIR" +trap 'rm -rf "$TEMP_DIR"' EXIT declare -A NEO_HASHES=( - ["intel-igc-core-2_2.34.4+21428_amd64.deb"]="1150de9f1b8c06aab0bf6e619a6c02ed4cd0c7b4135752ae74c82c8f8fb7acb2" - ["intel-igc-opencl-2_2.34.4+21428_amd64.deb"]="f36cb8a6899353c61cc7261b650f287f4a652acadaad859103bdfc51f93b6e8a" - ["intel-ocloc_26.18.38308.1-0_amd64.deb"]="74b98d91a92d59c487e4938175284e57d5a84ec35d9997a9d65fa4db3f51b96b" - ["intel-opencl-icd_26.18.38308.1-0_amd64.deb"]="b2d0c924e56b3f9e5837774d68b0c67461b8633035d93ca18b1a8e3e5ead15fa" + ["intel-igc-core-2_2.40.13+22418_amd64.deb"]="ebd795e9fddf303a9b24b7f04545d8ddd9ad1f85b3d0cb1166476fab24da6d44" + ["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]="4f990874efc11c3f6091a663b08aef576c4af592dcd8f12e116f8c2fc92d34d9" + ["intel-ocloc_26.31.39395.13-0_amd64.deb"]="12c5e61ed1dca5cbf38494e280abf88100a451580d57c44f601a17d9727e465e" + ["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]="5a9c9e8fdca8a2f9e22754b1a4618c7babf21d7c3ab3503c680005007c7a8c44" ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.18.38308.1-0_amd64.deb"]="12b8254e6d3415c32cee9cd13943030b991d91212445c79fe1cc27176a72eca4" + ["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]="1722943f81b576b9bb8d61016464208f48ce533dc3bf24ad39605293115cc289" ) download_and_verify() { @@ -46,31 +53,20 @@ download_and_verify() { fi } -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.34.4/intel-igc-core-2_2.34.4+21428_amd64.deb" \ - "intel-igc-core-2_2.34.4+21428_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.34.4+21428_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.34.4/intel-igc-opencl-2_2.34.4+21428_amd64.deb" \ - "intel-igc-opencl-2_2.34.4+21428_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.34.4+21428_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/intel-ocloc_26.18.38308.1-0_amd64.deb" \ - "intel-ocloc_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.18.38308.1-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/intel-opencl-icd_26.18.38308.1-0_amd64.deb" \ - "intel-opencl-icd_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.18.38308.1-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/libigdgmm12_22.10.0_amd64.deb" \ +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-core-2_2.40.13+22418_amd64.deb" \ + "intel-igc-core-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.40.13+22418_amd64.deb"]}" +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-opencl-2_2.40.13+22418_amd64.deb" \ + "intel-igc-opencl-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-ocloc_26.31.39395.13-0_amd64.deb" \ + "intel-ocloc_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-opencl-icd_26.31.39395.13-0_amd64.deb" \ + "intel-opencl-icd_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libigdgmm12_22.10.0_amd64.deb" \ "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.18.38308.1/libze-intel-gpu1_26.18.38308.1-0_amd64.deb" \ - "libze-intel-gpu1_26.18.38308.1-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.18.38308.1-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libze-intel-gpu1_26.31.39395.13-0_amd64.deb" \ + "libze-intel-gpu1_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]}" -dpkg -i libigdgmm12_22.10.0_amd64.deb - -dpkg -i intel-igc-core-2_2.34.4+21428_amd64.deb - -dpkg -i intel-igc-opencl-2_2.34.4+21428_amd64.deb - -dpkg -i intel-ocloc_26.18.38308.1-0_amd64.deb - -dpkg -i libze-intel-gpu1_26.18.38308.1-0_amd64.deb - -dpkg -i intel-opencl-icd_26.18.38308.1-0_amd64.deb -apt-get install -f -y +apt-get install -y ./*.deb cd / rm -rf "$TEMP_DIR" @@ -80,6 +76,6 @@ print_substep "Añadiendo usuario a grupos render y video..." if [ -n "${SUDO_USER:-}" ]; then usermod -a -G render,video "$SUDO_USER" else - current_user=$(logname 2>/dev/null || echo "$USER") + current_user="${SUDO_USER:-$(logname 2>/dev/null || id -un)}" usermod -a -G render,video "$current_user" fi From 52f99eac2321ce52919845af121a1c50d5583fd7 Mon Sep 17 00:00:00 2001 From: stornic56 <71296607+stornic56@users.noreply.github.com> Date: Mon, 28 Sep 2026 11:43:27 -0500 Subject: [PATCH 2/4] Update Openvino 2026.4 - Updated `VERSION` to `2026.4.0.22959.99c81491cc3` (was `2026.3.1.22476.56d9685302d`) - Updated all 6 NEO package hashes across Debian and Ubuntu modules (IGC, OpenCL, Compute Runtime, libigdgmm, libze-intel-gpu1) --- README.md | 8 ++++---- main.sh | 4 ++-- modules/setup_debian.sh | 32 ++++++++++++++++---------------- modules/setup_ubuntu.sh | 32 ++++++++++++++++---------------- 4 files changed, 38 insertions(+), 38 deletions(-) diff --git a/README.md b/README.md index e8734ff..2cacc5c 100644 --- a/README.md +++ b/README.md @@ -43,14 +43,14 @@ The execution of `main.sh` automatically handles OS detection and conditionally **Core Runtime & Libraries:** -* **OpenVINO Toolkit 2026.3.1:** The complete runtime package is downloaded from the official OpenVINO repository (`https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.3.1/linux`) and installed under `/opt/intel/openvino_2026`. It is the same version used in llama.cpp in its builds. +* **OpenVINO Toolkit 2026.4:** The complete runtime package is downloaded from the official OpenVINO repository (`https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.4/linux`) and installed under `/opt/intel/openvino_2026`. It is the same version used in llama.cpp in its builds. * **System Dependencies:** Required libraries, including `cmake`, Python 3 (with version-specific dependencies like `libpython3.13` for Debian 13 or `libpython3.13` for Ubuntu 26.04), GCC compilers (`g++`), NumPy bindings, and standard development tools are installed via system package managers (`apt`/`dnf`). **Hardware Acceleration & Drivers (NEO):** -* **Intel Compute Runtime NEO (26.31.39395.13):** If an Intel GPU is detected, the respective module script installs critical proprietary drivers: - * `intel-igc-core` (2.40.13): Graphics Compiler core components. - * `intel-igc-opencl` (2.40.13): OpenCL interface libraries for graphics compilation. +* **Intel Compute Runtime NEO (26.35.39758.10):** If an Intel GPU is detected, the respective module script installs critical proprietary drivers: + * `intel-igc-core` (2.41.5): Graphics Compiler core components. + * `intel-igc-opencl` (2.41.5): OpenCL interface libraries for graphics compilation. * `intel-ocloc`/`libze-intel-gpu1`: Compute Runtime interfaces and GPU acceleration layers (OpenCL/oneAPI). * **Multimedia Support:** Installation of `mesa-va-drivers`, `vainfo`, and related packages to ensure Video Acceleration API support, crucial for media inference tasks. diff --git a/main.sh b/main.sh index 78374a3..745dd50 100644 --- a/main.sh +++ b/main.sh @@ -119,8 +119,8 @@ fi # 4. Download OpenVINO Runtime # ------------------------------------------------------------------------------ print_step "4. Downloading OpenVINO Runtime package..." -BASE_URL="https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.3.1/linux" -VERSION="2026.3.1.22476.56d9685302d" +BASE_URL="https://storage.openvinotoolkit.org/repositories/openvino/packages/2026.4/linux" +VERSION="2026.4.0.22959.99c81491cc3" FILENAME="openvino_toolkit_${PREFIX}_${VERSION}_x86_64.tgz" URL="$BASE_URL/$FILENAME" diff --git a/modules/setup_debian.sh b/modules/setup_debian.sh index 3337ffd..98d97b7 100644 --- a/modules/setup_debian.sh +++ b/modules/setup_debian.sh @@ -45,12 +45,12 @@ trap 'rm -rf "$TEMP_DIR"' EXIT # Hashes SHA256 declare -A NEO_HASHES=( - ["intel-igc-core-2_2.40.13+22418_amd64.deb"]="ebd795e9fddf303a9b24b7f04545d8ddd9ad1f85b3d0cb1166476fab24da6d44" - ["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]="4f990874efc11c3f6091a663b08aef576c4af592dcd8f12e116f8c2fc92d34d9" - ["intel-ocloc_26.31.39395.13-0_amd64.deb"]="12c5e61ed1dca5cbf38494e280abf88100a451580d57c44f601a17d9727e465e" - ["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]="5a9c9e8fdca8a2f9e22754b1a4618c7babf21d7c3ab3503c680005007c7a8c44" + ["intel-igc-core-2_2.41.5+22716_amd64.deb"]="0a6e64a663ae65a0fa02d6912ae3b6b37cf85b90c21cc423fd9fef70aaf4f628" + ["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]="779e1b9e88098eb25711e9a8f67c2752665bad22f134aa40ed5649f6e1b87058" + ["intel-ocloc_26.35.39758.10-0_amd64.deb"]="c64bff586edf2bd9b49f3e4c9c2be25e05c43466e4dafa2a2c3948d498c736b7" + ["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]="61712caaddeba3d38e4f79e2a0fb23fea25596ca2d72c3144c6eea2331ec4301" ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]="1722943f81b576b9bb8d61016464208f48ce533dc3bf24ad39605293115cc289" + ["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]="c19a641b953d55aebbf1d51bec364a84bf629f985e02fbbe6dc70224c0e88470" ) download_and_verify() { @@ -65,18 +65,18 @@ download_and_verify() { fi } -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-core-2_2.40.13+22418_amd64.deb" \ - "intel-igc-core-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.40.13+22418_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-opencl-2_2.40.13+22418_amd64.deb" \ - "intel-igc-opencl-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-ocloc_26.31.39395.13-0_amd64.deb" \ - "intel-ocloc_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.31.39395.13-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-opencl-icd_26.31.39395.13-0_amd64.deb" \ - "intel-opencl-icd_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libigdgmm12_22.10.0_amd64.deb" \ +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-core-2_2.41.5+22716_amd64.deb" \ + "intel-igc-core-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.41.5+22716_amd64.deb"]}" +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-opencl-2_2.41.5+22716_amd64.deb" \ + "intel-igc-opencl-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-ocloc_26.35.39758.10-0_amd64.deb" \ + "intel-ocloc_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.35.39758.10-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-opencl-icd_26.35.39758.10-0_amd64.deb" \ + "intel-opencl-icd_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libigdgmm12_22.10.0_amd64.deb" \ "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libze-intel-gpu1_26.31.39395.13-0_amd64.deb" \ - "libze-intel-gpu1_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libze-intel-gpu1_26.35.39758.10-0_amd64.deb" \ + "libze-intel-gpu1_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]}" print_substep "Instalando paquetes deb..." apt-get install -y ./*.deb diff --git a/modules/setup_ubuntu.sh b/modules/setup_ubuntu.sh index 18b3488..614a279 100644 --- a/modules/setup_ubuntu.sh +++ b/modules/setup_ubuntu.sh @@ -33,12 +33,12 @@ cd "$TEMP_DIR" trap 'rm -rf "$TEMP_DIR"' EXIT declare -A NEO_HASHES=( - ["intel-igc-core-2_2.40.13+22418_amd64.deb"]="ebd795e9fddf303a9b24b7f04545d8ddd9ad1f85b3d0cb1166476fab24da6d44" - ["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]="4f990874efc11c3f6091a663b08aef576c4af592dcd8f12e116f8c2fc92d34d9" - ["intel-ocloc_26.31.39395.13-0_amd64.deb"]="12c5e61ed1dca5cbf38494e280abf88100a451580d57c44f601a17d9727e465e" - ["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]="5a9c9e8fdca8a2f9e22754b1a4618c7babf21d7c3ab3503c680005007c7a8c44" + ["intel-igc-core-2_2.41.5+22716_amd64.deb"]="0a6e64a663ae65a0fa02d6912ae3b6b37cf85b90c21cc423fd9fef70aaf4f628" + ["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]="779e1b9e88098eb25711e9a8f67c2752665bad22f134aa40ed5649f6e1b87058" + ["intel-ocloc_26.35.39758.10-0_amd64.deb"]="c64bff586edf2bd9b49f3e4c9c2be25e05c43466e4dafa2a2c3948d498c736b7" + ["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]="61712caaddeba3d38e4f79e2a0fb23fea25596ca2d72c3144c6eea2331ec4301" ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]="1722943f81b576b9bb8d61016464208f48ce533dc3bf24ad39605293115cc289" + ["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]="c19a641b953d55aebbf1d51bec364a84bf629f985e02fbbe6dc70224c0e88470" ) download_and_verify() { @@ -53,18 +53,18 @@ download_and_verify() { fi } -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-core-2_2.40.13+22418_amd64.deb" \ - "intel-igc-core-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.40.13+22418_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.40.13/intel-igc-opencl-2_2.40.13+22418_amd64.deb" \ - "intel-igc-opencl-2_2.40.13+22418_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.40.13+22418_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-ocloc_26.31.39395.13-0_amd64.deb" \ - "intel-ocloc_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.31.39395.13-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/intel-opencl-icd_26.31.39395.13-0_amd64.deb" \ - "intel-opencl-icd_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.31.39395.13-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libigdgmm12_22.10.0_amd64.deb" \ +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-core-2_2.41.5+22716_amd64.deb" \ + "intel-igc-core-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.41.5+22716_amd64.deb"]}" +download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-opencl-2_2.41.5+22716_amd64.deb" \ + "intel-igc-opencl-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-ocloc_26.35.39758.10-0_amd64.deb" \ + "intel-ocloc_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.35.39758.10-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-opencl-icd_26.35.39758.10-0_amd64.deb" \ + "intel-opencl-icd_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libigdgmm12_22.10.0_amd64.deb" \ "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.31.39395.13/libze-intel-gpu1_26.31.39395.13-0_amd64.deb" \ - "libze-intel-gpu1_26.31.39395.13-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.31.39395.13-0_amd64.deb"]}" +download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libze-intel-gpu1_26.35.39758.10-0_amd64.deb" \ + "libze-intel-gpu1_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]}" apt-get install -y ./*.deb From 252d4a83a02c82bd44fa838c63acda06e5ea4e31 Mon Sep 17 00:00:00 2001 From: stornic56 <71296607+stornic56@users.noreply.github.com> Date: Thu, 8 Oct 2026 15:13:24 -0500 Subject: [PATCH 3/4] Delete deps directory --- deps/install_openvino_dependencies.sh | 357 -------------------------- 1 file changed, 357 deletions(-) delete mode 100644 deps/install_openvino_dependencies.sh diff --git a/deps/install_openvino_dependencies.sh b/deps/install_openvino_dependencies.sh deleted file mode 100644 index c635db2..0000000 --- a/deps/install_openvino_dependencies.sh +++ /dev/null @@ -1,357 +0,0 @@ -#!/bin/bash - -# Copyright (C) 2018-2026 Intel Corporation -# SPDX-License-Identifier: Apache-2.0 - -# Modified by stornic56 (2026) to add support for Debian 13 (Trixie), Ubuntu 26.04, -# and Python 3.13 dependencies. Also ensures dnf is used on Fedora. - -set -euo pipefail - -#=================================================================================================== -# Option parsing - -all_comp=(core dev gpu python) -os=${os:-auto} - -# public options -interactive=yes -dry= -extra= -print= -comp=() - -# private options -keepcache= -selftest= - -while :; do - case "${1:-}" in - -h | -\? | --help) - echo "Options:" - echo " -y non-interactive run (off)" - echo " -n dry-run, assume no (off)" - echo " -c= install component , can be repeated (${all_comp[*]})" - echo " -e add extra repositories (RHEL 7, 8, 9) (off)" - echo " -p print package list and exit (off)" - exit - ;; - -y) interactive= ;; - -n) dry=yes ;; - -c=?*) comp+=("${1#*=}") ;; - -e) extra=yes ;; - -p) print=yes ;; - --selftest) selftest=yes ;; - --keepcache) keepcache=yes ;; - *) break ;; - esac - shift -done - -# No components selected - install default -if [ ${#comp[@]} -eq 0 ]; then - comp=("${all_comp[@]}") -fi - -#=================================================================================================== -# Selftest - -if [ -n "$selftest" ]; then - for image in centos:7 centos:8 rhel:8 rhel:9.1 \ - almalinux:8.7 amazonlinux:2 \ - fedora:34 fedora:35 fedora:36 fedora:37 fedora:38 \ - opensuse/leap:15.3 \ - raspbian:9 debian:9 ubuntu:18.04 \ - raspbian:10 debian:10 ubuntu:20.04 ubuntu:20.10 ubuntu:21.04 \ - raspbian:11 debian:11 ubuntu:21.10 ubuntu:22.04 \ - raspbian:12 debian:12 debian:13 ubuntu:22.10 ubuntu:23.04 ubuntu:24.04; do - for opt in "-h" "-p" "-e -p" "-n" "-n -e" "-y" "-y -e"; do - echo "||" - echo "|| Test $image / '$opt'" - echo "||" - SCRIPT_DIR="$(cd "$(dirname "$(realpath "${BASH_SOURCE:-$0}")")" >/dev/null 2>&1 && pwd)" - docker run -it --rm \ - --volume "${SCRIPT_DIR}":/scripts:ro,Z \ - --volume yum-cache:/var/cache/yum \ - --volume apt-cache:/var/cache/apt/archives \ - -e DEBIAN_FRONTEND=noninteractive \ - $image \ - bash "/scripts/${0##*/}" "$opt" --keepcache - echo "||" - echo "|| Completed: $image / '$opt'" - echo "||" - done - done - - for opt in "-h" "-p" "-e -p" "-n" "-n -e" "-y" "-y -e"; do - echo "||" - echo "|| Test ubuntu:26.04 / '$opt'" - echo "||" - SCRIPT_DIR="$(cd "$(dirname "$(realpath "${BASH_SOURCE:-$0}")")" >/dev/null 2>&1 && pwd)" - docker run -it --rm \ - --volume "${SCRIPT_DIR}":/scripts:ro,Z \ - --volume yum-cache:/var/cache/yum \ - --volume apt-cache:/var/cache/apt/archives \ - -e DEBIAN_FRONTEND=noninteractive \ - ubuntu:26.04 \ - bash "/scripts/${0##*/}" "$opt" --keepcache 2>/dev/null || true - echo "||" - echo "|| Completed: ubuntu:26.04 / '$opt'" - echo "||" - done - - echo "Self test finished, to remove temporary docker volumes run:" - echo "'docker volume rm yum-cache apt-cache'" - exit 0 -fi - -#=================================================================================================== -# OS detection - -if [ "$os" == "auto" ]; then - os="" - if [ -f /etc/os-release ]; then - os=$( - . /etc/os-release - echo "${ID:-}${VERSION_ID:-}" - ) - fi - if [[ "$os" =~ "rhel8".* ]]; then - os="rhel8" - fi - case $os in - centos7 | centos8 | centos9 | \ - rhel8 | rhel9.1 | rhel9.2 | rhel9.3 | rhel9.4 | \ - opencloudos8.5 | opencloudos8.6 | opencloudos8.8 | opencloudos9.0 | opencloudos9.2 | \ - tencentos3.1 | tencentos3.2 | tencentos3.3 | tencentos4.0 | tencentos4.2 | \ - anolis8.6 | anolis8.8 | \ - openEuler20.03 | openEuler22.03 | openEuler23.03 | openEuler24.03 | \ - almalinux8.7 | almalinux8.8 | almalinux9.2 | almalinux9.3 | almalinux9.4 | \ - amzn2 | amzn2022 | amzn2023 | \ - ol8.7 | ol8.8 | ol9.2 | ol9.3 | ol9.4 | \ - rocky8.7 | rocky8.8 | rocky9.2 | rocky9.3 | rocky9.4 | \ - fedora29 | fedora30 | fedora31 | fedora32 | fedora33 | fedora34 | fedora35 | fedora36 | \ - fedora37 | fedora38 | fedora39 | fedora40 | fedora41 | \ - fedora42 | fedora43 | fedora44 | fedora* | \ - opensuse-leap15.3 | \ - raspbian9 | debian9 | ubuntu18.04 | \ - raspbian10 | debian10 | ubuntu20.04 | ubuntu20.10 | ubuntu21.04 | \ - raspbian11 | debian11 | ubuntu21.10 | ubuntu22.04 | \ - raspbian12 | debian12 | debian13 | ubuntu22.10 | ubuntu23.04 | ubuntu23.10 | ubuntu24.04 | ubuntu26.04) [ -z "$print" ] && echo "Detected OS: ${os}" ;; - *) - echo "Unsupported OS: ${os:-detection failed}" >&2 - exit 1 - ;; - esac -fi - -#=================================================================================================== -# Collect packages - -extra_repos=() - -if [ "$os" == "raspbian9" ] || [ "$os" == "debian9" ]; then - pkgs_gpu=(ocl-icd-libopencl1) - pkgs_python=() - pkgs_dev=(pkg-config g++ gcc libc6-dev make sudo) - -elif [ "$os" == "ubuntu18.04" ]; then - pkgs_gpu=(ocl-icd-libopencl1) - pkgs_python=(python3.8 libpython3.8 python3.8-venv python3-pip) - pkgs_dev=(cmake pkg-config g++ gcc libc6-dev make sudo) - -elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || - [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || - [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || - [ "$os" == "debian13" ] || [ "$os" == "ubuntu26.04" ]; then - - pkgs_gpu=(ocl-icd-libopencl1) - pkgs_python=(python3 python3-venv python3-pip) - pkgs_dev=(cmake pkgconf g++ gcc libc6-dev make sudo) - - if [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ]; then - pkgs_python+=(libpython3.7) - elif [ "$os" == "ubuntu20.04" ] || [ "$os" == "ubuntu20.10" ] || [ "$os" == "ubuntu21.04" ]; then - pkgs_python+=(libpython3.8) - elif [ "$os" == "ubuntu21.10" ] || - [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ]; then - pkgs_python+=(libpython3.9) - elif [ "$os" == "ubuntu22.04" ] || [ "$os" == "ubuntu22.10" ] || - [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ]; then - pkgs_python+=(libpython3.10) - elif [ "$os" == "ubuntu23.04" ]; then - pkgs_python+=(libpython3.11) - elif [ "$os" == "ubuntu24.04" ]; then - pkgs_python+=(libpython3.12) - elif [ "$os" == "debian13" ]; then - pkgs_python+=(libpython3.13) - elif [ "$os" == "ubuntu25.04" ] || [ "$os" == "ubuntu26.04" ]; then - pkgs_python+=(libpython3.14) - fi - -elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "rhel8" ] || - [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || - [ "$os" == "opencloudos8.5" ] || [ "$os" == "opencloudos8.6" ] || [ "$os" == "opencloudos8.8" ] || - [ "$os" == "opencloudos9.0" ] || [ "$os" == "opencloudos9.2" ] || - [ "$os" == "tencentos3.1" ] || [ "$os" == "tencentos3.2" ] || [ "$os" == "tencentos3.3" ] || - [ "$os" == "tencentos4.0" ] || [ "$os" == "tencentos4.2" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || - [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ]; then - - arch=$(uname -m) - - if [ "$os" == "amzn2" ]; then - amazon-linux-extras install epel python3.8 - fi - - pkgs_gpu=() - pkgs_python=() - pkgs_dev=(gcc gcc-c++ make glibc libstdc++ libgcc cmake3 sudo) - - if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ]; then - pkgs_dev+=(pkgconfig) - else - pkgs_dev+=(pkgconf-pkg-config) - fi - - if [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ]; then - pkgs_python+=(python3 python3-pip) - fi - - if [ "$os" == "centos7" ] || [ "$os" == "amzn2" ]; then - pkgs_gpu+=("ocl-icd.$arch") - extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm") - elif [ "$os" == "rhel8" ]; then - pkgs_gpu+=("http://vault.centos.org/centos/8-stream/AppStream/$arch/os/Packages/ocl-icd-2.2.12-1.el8.$arch.rpm") - pkgs_python+=(python38 python38-pip) - extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm") - elif [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ]; then - pkgs_gpu+=("https://mirror.stream.centos.org/9-stream/AppStream/$arch/os/Packages/ocl-icd-2.2.13-4.el9.$arch.rpm") - pkgs_python+=(python3 python3-pip) - extra_repos+=("https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm") - fi -elif [ "$os" == "opensuse-leap15.3" ]; then - pkgs_gpu=(libOpenCL1) - pkgs_python=(python39-base python39 python39-venv python39-pip) - pkgs_dev=(cmake pkg-config gcc-c++ gcc make sudo) -else - echo "Internal script error: invalid OS (${os}) after check (package selection)" >&2 - exit 3 -fi - -#=================================================================================================== -# Gather packages and print list - -pkgs=() -for comp in "${comp[@]}"; do - var="pkgs_${comp}[@]" - pkgs+=("${!var}") -done - -if [ ${#pkgs[@]} -eq 0 ]; then - if [ -n "$print" ]; then - echo "No packages to install" >&2 - exit 1 - else - echo "No packages to install" - exit 0 - fi -fi - -if [ -n "$print" ]; then - echo "${pkgs[*]}" - exit 0 -fi - -#=================================================================================================== -# Actual installation - -if [ $EUID -ne 0 ]; then - echo "ERROR: this script must be run as root to install 3rd party packages." >&2 - echo "Please try again with \"sudo -E $0\", or as root." >&2 - exit 1 -fi - -iopt= - -if [ "$os" == "debian9" ] || [ "$os" == "raspbian9" ] || [ "$os" == "ubuntu18.04" ] || - [ "$os" == "debian10" ] || [ "$os" == "raspbian10" ] || [ "$os" == "ubuntu20.04" ] || [ "$os" == "ubuntu20.10" ] || [ "$os" == "ubuntu21.04" ] || - [ "$os" == "debian11" ] || [ "$os" == "raspbian11" ] || [ "$os" == "ubuntu21.10" ] || [ "$os" == "ubuntu22.04" ] || - [ "$os" == "debian12" ] || [ "$os" == "raspbian12" ] || [ "$os" == "debian13" ] || [ "$os" == "ubuntu22.10" ] || [ "$os" == "ubuntu23.04" ] || [ "$os" == "ubuntu23.10" ] || [ "$os" == "ubuntu24.04" ] || [ "$os" == "ubuntu26.04" ]; then - - [ -z "$interactive" ] && iopt="-y" - [ -n "$dry" ] && iopt="--dry-run" - [ -n "$keepcache" ] && rm -f /etc/apt/apt.conf.d/docker-clean - - apt-get update && apt-get install --no-install-recommends "$iopt" "${pkgs[@]}" - -elif [ "$os" == "centos7" ] || [ "$os" == "centos8" ] || [ "$os" == "centos9" ] || - [ "$os" == "rhel8" ] || - [ "$os" == "rhel9.1" ] || [ "$os" == "rhel9.2" ] || [ "$os" == "rhel9.3" ] || [ "$os" == "rhel9.4" ] || - [ "$os" == "anolis8.6" ] || [ "$os" == "anolis8.8" ] || - [ "$os" == "openEuler20.03" ] || [ "$os" == "openEuler22.03" ] || [ "$os" == "openEuler23.03" ] || [ "$os" == "openEuler24.03" ] || - [ "$os" == "fedora29" ] || [ "$os" == "fedora30" ] || [ "$os" == "fedora31" ] || [ "$os" == "fedora32" ] || - [ "$os" == "fedora33" ] || [ "$os" == "fedora34" ] || [ "$os" == "fedora35" ] || [ "$os" == "fedora36" ] || - [ "$os" == "fedora37" ] || [ "$os" == "fedora38" ] || [ "$os" == "fedora39" ] || [ "$os" == "fedora40" ] || - [ "$os" == "fedora41" ] || [ "$os" == "fedora42" ] || [ "$os" == "fedora43" ] || [ "$os" == "fedora44" ] || [[ "$os" == fedora* ]] || - [ "$os" == "ol8.7" ] || [ "$os" == "ol8.8" ] || - [ "$os" == "ol9.2" ] || [ "$os" == "ol9.3" ] || [ "$os" == "ol9.4" ] || - [ "$os" == "rocky8.7" ] || [ "$os" == "rocky8.8" ] || - [ "$os" == "rocky9.2" ] || [ "$os" == "rocky9.3" ] || [ "$os" == "rocky9.4" ] || - [ "$os" == "almalinux8.7" ] || [ "$os" == "almalinux8.8" ] || - [ "$os" == "almalinux9.2" ] || [ "$os" == "almalinux9.3" ] || [ "$os" == "almalinux9.4" ] || - [ "$os" == "amzn2" ] || [ "$os" == "amzn2022" ] || [ "$os" == "amzn2023" ]; then - - # Usar dnf en Fedora moderna, yum en el resto - if [[ "$os" == fedora* ]]; then - PKGCMD="dnf" - else - PKGCMD="yum" - fi - - [ -z "$interactive" ] && iopt="--assumeyes" - [ -n "$dry" ] && iopt="--downloadonly" - [ -n "$keepcache" ] && iopt="$iopt --setopt=keepcache=1" - [ -n "$extra" ] && [ ${#extra_repos[@]} -ne 0 ] && $PKGCMD localinstall ${iopt:+$iopt} --nogpgcheck "${extra_repos[@]}" - - $PKGCMD install ${iopt:+$iopt} "${pkgs[@]}" - -elif [ "$os" == "opensuse-leap15.3" ]; then - - [ -z "$interactive" ] && iopt="-y" - [ -n "$dry" ] && iopt="--dry-run" - [ -n "$keepcache" ] && zypper clean --all - - zypper ref && zypper in --auto-agree-with-licenses --no-recommends "$iopt" "${pkgs[@]}" - -else - echo "Internal script error: invalid OS (${os}) after check (package installation)" >&2 - exit 3 -fi - -exit 0 From cbc405a4862b206ec021c277b9cba807f96eed83 Mon Sep 17 00:00:00 2001 From: stornic56 <71296607+stornic56@users.noreply.github.com> Date: Thu, 8 Oct 2026 15:16:33 -0500 Subject: [PATCH 4/4] fix An issue with the verification and extraction of the .tgz file was resolved. --- core/common.sh | 15 +++-- core/doctor.sh | 71 +++++++++++++++++++++ core/menu.sh | 62 +++++++++++++++++++ core/neo_apt.sh | 75 +++++++++++++++++++++++ core/openvino_logic.sh | 45 +++++++++++--- core/uninstall.sh | 57 +++++++++++++++++ main.sh | 132 ++++++++++++++++++++++++++++++++-------- modules/setup_debian.sh | 38 +----------- modules/setup_ubuntu.sh | 39 +----------- 9 files changed, 425 insertions(+), 109 deletions(-) create mode 100644 core/doctor.sh create mode 100644 core/menu.sh create mode 100644 core/neo_apt.sh create mode 100644 core/uninstall.sh diff --git a/core/common.sh b/core/common.sh index 7e3094b..b75212b 100644 --- a/core/common.sh +++ b/core/common.sh @@ -1,9 +1,16 @@ #!/bin/bash # ------------------------------------------------------------------------------ # Common printing functions for all installer scripts. +# Dual output: colores ANSI a stdout + texto plano (sin codigos) a $LOG_FILE. +# El log es AUXILIAR: su fallo de escritura no debe abortar la operacion +# (p. ej. log root-owned + doctor sin root) — por eso el append va guardado. # ------------------------------------------------------------------------------ -print_step() { echo -e "\n\033[1;34m>>>\033[0m \033[1m$1\033[0m"; } -print_substep() { echo -e "\033[1;32m =>\033[0m $1"; } -print_warning() { echo -e "\033[1;33m [AVISO]\033[0m $1"; } -print_error() { echo -e "\033[1;31m [ERROR]\033[0m $1"; } +LOG_FILE="${LOG_FILE:-install.log}" + +_log_plain() { printf '%s\n' "$1" >> "$LOG_FILE" 2>/dev/null || true; } + +print_step() { echo -e "\n\033[1;34m>>>\033[0m \033[1m$1\033[0m"; _log_plain ""; _log_plain ">>> $1"; } +print_substep() { echo -e "\033[1;32m =>\033[0m $1"; _log_plain " => $1"; } +print_warning() { echo -e "\033[1;33m [WARNING]\033[0m $1"; _log_plain " [WARNING] $1"; } +print_error() { echo -e "\033[1;31m [ERROR]\033[0m $1"; _log_plain " [ERROR] $1"; } diff --git a/core/doctor.sh b/core/doctor.sh new file mode 100644 index 0000000..eafe901 --- /dev/null +++ b/core/doctor.sh @@ -0,0 +1,71 @@ +#!/bin/bash +# ------------------------------------------------------------------------------ +# doctor: post-installation verification (no root required). +# Sourced by main.sh (doctor subcommand) and by the menu. +# Output with print_* from common.sh; exit code = number of failed checks. +# ------------------------------------------------------------------------------ + +run_doctor_checks() { + print_step "Doctor: verifying OpenVINO installation..." + local fails=0 + + # 1. Stable symlink + if [ -L /opt/intel/openvino_2026 ]; then + print_substep "Symlink OK: /opt/intel/openvino_2026 -> $(readlink /opt/intel/openvino_2026)" + else + print_error "Missing symlink /opt/intel/openvino_2026 (was the installation performed?)" + fails=$((fails+1)) + fi + + # 2. Installed version + if [ -f /opt/intel/openvino_2026/runtime/version.txt ]; then + print_substep "Installed version: $(cat /opt/intel/openvino_2026/runtime/version.txt)" + else + print_error "runtime/version.txt not found" + fails=$((fails+1)) + fi + + # 3. OpenCL (clinfo) — capture first (clinfo output is large; grep -q would + # SIGPIPE-kill the pipe and report a false negative under pipefail) + if command -v clinfo >/dev/null 2>&1; then + CLINFO_OUT=$(clinfo 2>/dev/null || true) # clinfo exits !=0 when no devices + if [[ "${CLINFO_OUT^^}" == *"DEVICE NAME"* ]]; then + print_substep "OpenCL OK (device detected)" + else + print_warning "clinfo does not detect a device (missing NEO driver or render/video groups?)" + fails=$((fails+1)) + fi + else + print_warning "clinfo is not installed" + fails=$((fails+1)) + fi + + # 4. VAAPI (vainfo) — same capture-first pattern (consistency + latent SIGPIPE) + if command -v vainfo >/dev/null 2>&1; then + VAINFO_OUT=$(vainfo 2>/dev/null || true) + if [[ "${VAINFO_OUT^^}" == *"DRIVER VERSION"* ]]; then + print_substep "VAAPI OK (driver loaded)" + else + print_warning "vainfo does not load a driver (missing intel-media-va-driver?)" + fails=$((fails+1)) + fi + else + print_warning "vainfo is not installed" + fails=$((fails+1)) + fi + + # 5. render/video groups + if id -Gn 2>/dev/null | grep -qw render && id -Gn 2>/dev/null | grep -qw video; then + print_substep "Groups OK: user is in render and video" + else + print_warning "User is NOT in the render/video groups (restart your session after installing)" + fails=$((fails+1)) + fi + + if [ "$fails" -eq 0 ]; then + print_substep "Doctor: ALL OK" + else + print_warning "Doctor: $fails check(s) with warnings or failures" + fi + return "$fails" +} diff --git a/core/menu.sh b/core/menu.sh new file mode 100644 index 0000000..c73a2ea --- /dev/null +++ b/core/menu.sh @@ -0,0 +1,62 @@ +#!/bin/bash +# ------------------------------------------------------------------------------ +# Minimalist pure-bash menu (zero external dependencies: ANSI + read -sn1). +# Navigation: up/down arrows + Enter, number keys as a shortcut, q/ESC exit. +# Returns: 0=exit, 1=full installation, 2=NEO only, 3=OpenVINO only, +# 4=doctor, 5=uninstall +# Requires: common.sh already sourced (print_*), no root needed to navigate. +# ------------------------------------------------------------------------------ + +MENU_OPTS=("Full installation" "NEO drivers only" "OpenVINO Runtime only" "Verify installation (doctor)" "Uninstall" "Exit") + +show_menu() { + local sel=0 + local n=${#MENU_OPTS[@]} + local key rest i opt pad + while true; do + printf '\033[2J\033[H' + echo "" + echo "┌──────────────────────────────────────────────┐" + echo "│ OpenVINO Simple Installer 2026.4 │" + echo "└──────────────────────────────────────────────┘" + echo "" + i=0 + for opt in "${MENU_OPTS[@]}"; do + pad=$(( 38 - ${#opt} )) + if [ "$i" -eq "$sel" ]; then + printf '│ \033[1;34m▸ %s. %s\033[0m%*s│\n' "$((i+1))" "$opt" "$pad" "" + else + printf '│ %s. %s%*s│\n' "$((i+1))" "$opt" "$pad" "" + fi + i=$((i+1)) + done + echo "└──────────────────────────────────────────────┘" + echo "" + echo " Arrows + Enter · number + Enter · q/ESC exit" + if ! read -rsn1 key; then + print_error "No input available." + return 0 + fi + if [ "$key" = $'\x1b' ]; then + rest="" + read -rsn2 -t 0.001 rest || true + case "$rest" in + '[A') sel=$(( (sel - 1 + n) % n )) ;; + '[B') sel=$(( (sel + 1) % n )) ;; + *) return 0 ;; # ESC sin flecha: salir + esac + elif [ "$key" = "" ]; then + # Enter: seleccionar la opcion marcada + [ "$sel" -eq $((n-1)) ] && return 0 + return $((sel+1)) + elif [[ "$key" =~ ^[0-9]$ ]]; then + # Atajo numerico: 1..5 seleccionan, 0 sale + [ "$key" = "0" ] && return 0 + if [ "$key" -ge 1 ] && [ "$key" -le $((n-1)) ]; then + return "$key" + fi + elif [ "$key" = "q" ]; then + return 0 + fi + done +} diff --git a/core/neo_apt.sh b/core/neo_apt.sh new file mode 100644 index 0000000..27b15ce --- /dev/null +++ b/core/neo_apt.sh @@ -0,0 +1,75 @@ +#!/bin/bash +# ------------------------------------------------------------------------------ +# Shared NEO block: version variables, SHA256 hashes, download with +# verification and install via apt. Sourced by the setup_*.sh modules. +# +# The next version update changes ONLY the 4 variables here +# (+ the NEO_HASHES values if the hashes change). +# Requires: common.sh already sourced (uses print_*), CWD = TEMP_DIR when +# calling install_neo_packages. +# ------------------------------------------------------------------------------ + +# --- Versions (pinned; no auto-detection) --- +IGC_TAG="v2.41.5" # release tag in intel/intel-graphics-compiler +IGC_BUILD="22716" # IGC package build: 2.41.5+22716 +IGC_VERSION="${IGC_TAG#v}" # derived: 2.41.5 +NEO_VERSION="26.35.39758.10" # release in intel/compute-runtime +GMM_VERSION="22.10.0" # libigdgmm12 (stable across releases) + +# --- SHA256 hashes by package name (values change with each version) --- +declare -A NEO_HASHES=( + ["intel-igc-core-2"]="0a6e64a663ae65a0fa02d6912ae3b6b37cf85b90c21cc423fd9fef70aaf4f628" + ["intel-igc-opencl-2"]="779e1b9e88098eb25711e9a8f67c2752665bad22f134aa40ed5649f6e1b87058" + ["intel-ocloc"]="c64bff586edf2bd9b49f3e4c9c2be25e05c43466e4dafa2a2c3948d498c736b7" + ["intel-opencl-icd"]="61712caaddeba3d38e4f79e2a0fb23fea25596ca2d72c3144c6eea2331ec4301" + ["libigdgmm12"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" + ["libze-intel-gpu1"]="c19a641b953d55aebbf1d51bec364a84bf629f985e02fbbe6dc70224c0e88470" +) + +# --- Package filename by family --- +neo_pkg_filename() { + case "$1" in + intel-igc-core-2|intel-igc-opencl-2) + echo "${1}_${IGC_VERSION}+${IGC_BUILD}_amd64.deb" ;; + libigdgmm12) + echo "${1}_${GMM_VERSION}_amd64.deb" ;; + *) + echo "${1}_${NEO_VERSION}-0_amd64.deb" ;; + esac +} + +# --- Download URL by family --- +neo_pkg_url() { + case "$1" in + intel-igc-core-2|intel-igc-opencl-2) + echo "https://github.com/intel/intel-graphics-compiler/releases/download/${IGC_TAG}/$(neo_pkg_filename "$1")" ;; + *) + echo "https://github.com/intel/compute-runtime/releases/download/${NEO_VERSION}/$(neo_pkg_filename "$1")" ;; + esac +} + +# --- Download with SHA256 verification --- +download_and_verify() { + local url="$1" + local filename="$2" + local expected="$3" + wget -q --show-progress "$url" -O "$filename" + local actual + actual=$(sha256sum "$filename" | awk '{print $1}') + if [ "$actual" != "$expected" ]; then + print_error "SHA256 mismatch for $filename" + exit 1 + fi +} + +# --- Download + verify + install of the 6 production packages --- +install_neo_packages() { + local pkg f + for pkg in intel-igc-core-2 intel-igc-opencl-2 intel-ocloc libigdgmm12 libze-intel-gpu1 intel-opencl-icd; do + f="$(neo_pkg_filename "$pkg")" + download_and_verify "$(neo_pkg_url "$pkg")" "$f" "${NEO_HASHES[$pkg]}" + done + + print_substep "Installing deb packages..." + apt-get install -y ./*.deb +} diff --git a/core/openvino_logic.sh b/core/openvino_logic.sh index ca0e278..bddee21 100644 --- a/core/openvino_logic.sh +++ b/core/openvino_logic.sh @@ -6,10 +6,40 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" source "$SCRIPT_DIR/common.sh" if [ $# -lt 2 ]; then - print_error "Usage: $0 | $0 --install " + print_error "Usage: $0 | $0 --extract | $0 --install " exit 1 fi +if [ "$1" = "--extract" ]; then + FILENAME="$2" + if [ ! -f "$FILENAME" ]; then + print_error " $FILENAME could not be found to extract." + exit 1 + fi + + # Known before tar (enables partial-extraction cleanup on abort) + DIRNAME="${FILENAME%.tgz}" + # Cleanup ONLY on abort: the trap is set before tar and DISARMED on success — + # otherwise the EXIT trap deletes the just-extracted folder on 'exit 0' and + # the deps step (and the later --install) find nothing. + trap 'rm -rf "$DIRNAME"' EXIT + + print_substep "Unzipping $FILENAME..." + if ! tar -xf "$FILENAME"; then + print_error "Extraction of $FILENAME failed." + exit 1 # trap fires: partial extraction is cleaned up + fi + trap - EXIT # success: keep the extracted folder for the deps and install steps + + # fallback if the extracted folder name differs from the tarball name + if [ ! -d "$DIRNAME" ]; then + TAR_LIST=$(tar -tf "$FILENAME") + DIRNAME="${TAR_LIST%%$'\n'*}" # first entry (no pipe, no SIGPIPE) + DIRNAME="${DIRNAME%%/*}" + fi + exit 0 +fi + if [ "$1" = "--install" ]; then FILENAME="$2" if [ ! -f "$FILENAME" ]; then @@ -30,9 +60,9 @@ if [ "$1" = "--install" ]; then INSTALL_DIR="/opt/intel/openvino_$(echo "$VERSION_FULL" | cut -d. -f1-3)" # Replace policy (updates): remove ANY previous 2026 install and the previous symlink. - # Known limitation: the previous install is deleted BEFORE extracting; if the tar - # failed afterwards, the system would be left without OpenVINO. Acceptable because - # the SHA256 was already verified during the download step. + # Known limitation: the previous install is deleted BEFORE moving the new one; if the + # mv failed afterwards, the system would be left without OpenVINO. Acceptable because + # the extraction and its SHA256 verification already succeeded in the --extract step. if ls -d /opt/intel/openvino_2026.* >/dev/null 2>&1; then print_warning "An existing OpenVINO installation was found. Replacing it..." fi @@ -40,10 +70,7 @@ if [ "$1" = "--install" ]; then rm -rf /opt/intel/openvino_2026.* # ANY previous 2026 install mkdir -p /opt/intel - DIRNAME="${FILENAME%.tgz}" # known before tar (enables trap cleanup) - trap 'rm -rf "$DIRNAME"' EXIT - print_substep "Unzipping $FILENAME..." - tar -xf "$FILENAME" + DIRNAME="${FILENAME%.tgz}" if [ ! -d "$DIRNAME" ]; then # guess the real name @@ -51,7 +78,7 @@ if [ "$1" = "--install" ]; then DIRNAME="${TAR_LIST%%$'\n'*}" # first entry (no pipe, no SIGPIPE) DIRNAME="${DIRNAME%%/*}" fi - print_substep "Moving $DIRNAME a $INSTALL_DIR..." + print_substep "Moving $DIRNAME to $INSTALL_DIR..." mv "$DIRNAME" "$INSTALL_DIR" print_substep "Create symbolic link /opt/intel/openvino_2026..." diff --git a/core/uninstall.sh b/core/uninstall.sh new file mode 100644 index 0000000..dc1692b --- /dev/null +++ b/core/uninstall.sh @@ -0,0 +1,57 @@ +#!/bin/bash +# ------------------------------------------------------------------------------ +# uninstall: removes OpenVINO Runtime (and optionally the NEO drivers). +# Sourced by main.sh (uninstall subcommand). Requires root to operate. +# Arguments: --purge-drivers (dpkg -r of the 6 NEO packages), --yes (no prompt). +# ------------------------------------------------------------------------------ + +run_uninstall() { + local PURGE_DRIVERS=false + local ASSUME_YES=false + while [ $# -gt 0 ]; do + case "$1" in + --purge-drivers) PURGE_DRIVERS=true ;; + --yes) ASSUME_YES=true ;; + *) break ;; + esac + shift + done + + if [ "$EUID" -ne 0 ]; then + print_error "uninstall requires root. Use: sudo bash main.sh uninstall [--purge-drivers] [--yes]" + exit 1 + fi + + print_step "Uninstall: removing OpenVINO Runtime..." + + # Mandatory confirmation (skipped with --yes) + if [ "$ASSUME_YES" != true ]; then + read -r -p "This will remove /opt/intel/openvino_2026* (all 2026 installations). Continue? [y/n]: " response || { + print_error "No input available. Uninstall cancelled." + exit 1 + } + case "$response" in + [yY]*) ;; + *) + print_error "Uninstall cancelled by the user." + exit 0 + ;; + esac + fi + + # Runtime: symlink OR real directory + any 2026 installation + # (rm -rf does not follow symlinks — covers both cases) + rm -rf /opt/intel/openvino_2026 + rm -rf /opt/intel/openvino_2026.* + print_substep "OpenVINO Runtime removed (/opt/intel/openvino_2026*)" + + # NEO drivers (optional, best-effort with a warning) + if [ "$PURGE_DRIVERS" = true ]; then + print_substep "Purging NEO drivers (dpkg -r)..." + if ! dpkg -r intel-opencl-icd intel-ocloc libigdgmm12 libze-intel-gpu1 intel-igc-core-2 intel-igc-opencl-2 2>/dev/null; then + print_warning "Some NEO packages were not installed (on Fedora: dnf remove intel-compute-runtime)" + fi + fi + + print_substep "Uninstall completed." +} diff --git a/main.sh b/main.sh index 745dd50..52432ec 100644 --- a/main.sh +++ b/main.sh @@ -7,6 +7,79 @@ set -euo pipefail # It supports Debian 13, Ubuntu 22.04/24.04/26.04, and Fedora (latest stable versions). # ------------------------------------------------------------------------------ +# routes +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +CORE_DIR="$SCRIPT_DIR/core" +MODULES_DIR="$SCRIPT_DIR/modules" + +# print +source "$CORE_DIR/common.sh" + +# Subcommands (before the root check: doctor is a post-install user verification) +case "${1:-}" in + doctor) + shift + source "$CORE_DIR/doctor.sh" + run_doctor_checks + exit 0 + ;; + uninstall) + shift + source "$CORE_DIR/uninstall.sh" + run_uninstall "$@" + exit 0 + ;; +esac + +# Option parsing (before the root check: parsing needs no privileges) +ASSUME_YES=false +FORCE_NO_GPU=false +while [ $# -gt 0 ]; do + case "$1" in + --yes) ASSUME_YES=true ;; + --no-gpu) FORCE_NO_GPU=true ;; + --help | -h) + echo "Usage: sudo bash main.sh [--yes] [--no-gpu] [doctor]" + echo " --yes non-interactive: assume 'yes' at the GPU-absent prompt" + echo " --no-gpu skip NEO drivers without prompting" + echo " doctor post-install verification (no root required)" + exit 0 + ;; + *) + print_error "Unknown option: $1 (use --help)" + exit 1 + ;; + esac + shift +done + +# Menu (Pure-bash ANSI, cero dependencias): la entrada por defecto; los flags la bypassan +MODE="full" +if [ "$ASSUME_YES" != true ] && [ "$FORCE_NO_GPU" != true ]; then + source "$CORE_DIR/menu.sh" + sel=0 + show_menu || sel=$? + case "$sel" in + 0) + print_step "See you soon." + exit 0 + ;; + 1) : ;; + 2) MODE="neo" ;; + 3) MODE="openvino" ;; + 4) + source "$CORE_DIR/doctor.sh" + run_doctor_checks + exit 0 + ;; + 5) + source "$CORE_DIR/uninstall.sh" + run_uninstall + exit 0 + ;; + esac +fi + # privileges if [ "$EUID" -ne 0 ]; then echo "ERROR: This script must be run as root. Use:" @@ -14,15 +87,6 @@ if [ "$EUID" -ne 0 ]; then exit 1 fi -# routes -SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" -CORE_DIR="$SCRIPT_DIR/core" -MODULES_DIR="$SCRIPT_DIR/modules" -DEPS_DIR="$SCRIPT_DIR/deps" - -# print -source "$CORE_DIR/common.sh" - print_step "=============================================" print_step " OpenVINO 2026 - SimpleInstaller" print_step "=============================================" @@ -82,23 +146,29 @@ if [ -n "$GPU_LINE" ]; then else print_warning "No Intel GPU was detected." GPU_PRESENT=false - read -r -p "Do you want to continue the installation WITHOUT GPU support? [y/n]: " response || { - print_error "No interactive input available (stdin closed). Installation cancelled." - exit 1 - } - case "$response" in - [yY]*) ;; - *) - print_error "Installation cancelled by the user." - exit 0 - ;; - esac + if [ "$FORCE_NO_GPU" = true ]; then + print_substep "--no-gpu set: skipping NEO driver installation." + elif [ "$ASSUME_YES" = true ]; then + print_substep "--yes set: continuing WITHOUT GPU support." + else + read -r -p "Do you want to continue the installation WITHOUT GPU support? [y/n]: " response || { + print_error "No interactive input available (stdin closed). Installation cancelled." + exit 1 + } + case "$response" in + [yY]*) ;; + *) + print_error "Installation cancelled by the user." + exit 0 + ;; + esac + fi fi # ------------------------------------------------------------------------------ # 3. Install NEO (only if there is a GPU) # ------------------------------------------------------------------------------ -if [ "$GPU_PRESENT" = true ]; then +if [ "$MODE" != "openvino" ] && [ "$GPU_PRESENT" = true ]; then print_step "3. Installing GPU drivers (Intel Compute Runtime NEO)..." case "$OS_ID" in debian) @@ -115,6 +185,11 @@ else print_step "3. Skipping NEO driver installation (no Intel GPU)." fi +if [ "$MODE" = "neo" ]; then + print_step "NEO installation finished." + exit 0 +fi + # ------------------------------------------------------------------------------ # 4. Download OpenVINO Runtime # ------------------------------------------------------------------------------ @@ -132,10 +207,19 @@ bash "$CORE_DIR/openvino_logic.sh" "$URL" "$FILENAME" print_step "5. Integrity verification completed." # ------------------------------------------------------------------------------ -# 6. Install system dependencies for OpenVINO # ------------------------------------------------------------------------------ -print_step "6. Installing system dependencies (Python, cmake, etc.)..." -bash "$DEPS_DIR/install_openvino_dependencies.sh" -y +# 6. Extract the tarball and install system dependencies from it (official flow) +# ------------------------------------------------------------------------------ +print_step "6. Extracting tarball and installing system dependencies..." +bash "$CORE_DIR/openvino_logic.sh" --extract "$FILENAME" + +DEPS_SCRIPT="${FILENAME%.tgz}/install_dependencies/install_openvino_dependencies.sh" +if [ ! -f "$DEPS_SCRIPT" ]; then + print_error "Unexpected tarball layout: install_dependencies/ not found in the extracted folder." + exit 1 +fi +print_substep "Installing system dependencies from the tarball..." +bash "$DEPS_SCRIPT" -y # ------------------------------------------------------------------------------ # 7. Install OpenVINO diff --git a/modules/setup_debian.sh b/modules/setup_debian.sh index 98d97b7..04b2d11 100644 --- a/modules/setup_debian.sh +++ b/modules/setup_debian.sh @@ -4,6 +4,7 @@ set -euo pipefail SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" source "$SCRIPT_DIR/../core/common.sh" +source "$SCRIPT_DIR/../core/neo_apt.sh" print_step "Debian Module – Drivers and Multimedia" @@ -44,42 +45,7 @@ cd "$TEMP_DIR" trap 'rm -rf "$TEMP_DIR"' EXIT # Hashes SHA256 -declare -A NEO_HASHES=( - ["intel-igc-core-2_2.41.5+22716_amd64.deb"]="0a6e64a663ae65a0fa02d6912ae3b6b37cf85b90c21cc423fd9fef70aaf4f628" - ["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]="779e1b9e88098eb25711e9a8f67c2752665bad22f134aa40ed5649f6e1b87058" - ["intel-ocloc_26.35.39758.10-0_amd64.deb"]="c64bff586edf2bd9b49f3e4c9c2be25e05c43466e4dafa2a2c3948d498c736b7" - ["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]="61712caaddeba3d38e4f79e2a0fb23fea25596ca2d72c3144c6eea2331ec4301" - ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]="c19a641b953d55aebbf1d51bec364a84bf629f985e02fbbe6dc70224c0e88470" -) - -download_and_verify() { - local url="$1" - local filename="$2" - local expected="$3" - wget -q --show-progress "$url" -O "$filename" - actual=$(sha256sum "$filename" | awk '{print $1}') - if [ "$actual" != "$expected" ]; then - print_error "SHA256 mismatch para $filename" - exit 1 - fi -} - -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-core-2_2.41.5+22716_amd64.deb" \ - "intel-igc-core-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.41.5+22716_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-opencl-2_2.41.5+22716_amd64.deb" \ - "intel-igc-opencl-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-ocloc_26.35.39758.10-0_amd64.deb" \ - "intel-ocloc_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.35.39758.10-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-opencl-icd_26.35.39758.10-0_amd64.deb" \ - "intel-opencl-icd_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libigdgmm12_22.10.0_amd64.deb" \ - "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libze-intel-gpu1_26.35.39758.10-0_amd64.deb" \ - "libze-intel-gpu1_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]}" - -print_substep "Instalando paquetes deb..." -apt-get install -y ./*.deb +install_neo_packages cd / rm -rf "$TEMP_DIR" diff --git a/modules/setup_ubuntu.sh b/modules/setup_ubuntu.sh index 614a279..3905b55 100644 --- a/modules/setup_ubuntu.sh +++ b/modules/setup_ubuntu.sh @@ -3,6 +3,7 @@ set -euo pipefail SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" source "$SCRIPT_DIR/../core/common.sh" +source "$SCRIPT_DIR/../core/neo_apt.sh" print_step "Ubuntu Module – Drivers and Multimedia" @@ -32,47 +33,13 @@ TEMP_DIR=$(mktemp -d) cd "$TEMP_DIR" trap 'rm -rf "$TEMP_DIR"' EXIT -declare -A NEO_HASHES=( - ["intel-igc-core-2_2.41.5+22716_amd64.deb"]="0a6e64a663ae65a0fa02d6912ae3b6b37cf85b90c21cc423fd9fef70aaf4f628" - ["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]="779e1b9e88098eb25711e9a8f67c2752665bad22f134aa40ed5649f6e1b87058" - ["intel-ocloc_26.35.39758.10-0_amd64.deb"]="c64bff586edf2bd9b49f3e4c9c2be25e05c43466e4dafa2a2c3948d498c736b7" - ["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]="61712caaddeba3d38e4f79e2a0fb23fea25596ca2d72c3144c6eea2331ec4301" - ["libigdgmm12_22.10.0_amd64.deb"]="6031a63d6e8a12ce61c14efc15f2c8e727061286e3820b8594e6d00615e04d54" - ["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]="c19a641b953d55aebbf1d51bec364a84bf629f985e02fbbe6dc70224c0e88470" -) - -download_and_verify() { - local url="$1" - local filename="$2" - local expected="$3" - wget -q --show-progress "$url" -O "$filename" - actual=$(sha256sum "$filename" | awk '{print $1}') - if [ "$actual" != "$expected" ]; then - print_error "SHA256 mismatch para $filename" - exit 1 - fi -} - -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-core-2_2.41.5+22716_amd64.deb" \ - "intel-igc-core-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-core-2_2.41.5+22716_amd64.deb"]}" -download_and_verify "https://github.com/intel/intel-graphics-compiler/releases/download/v2.41.5/intel-igc-opencl-2_2.41.5+22716_amd64.deb" \ - "intel-igc-opencl-2_2.41.5+22716_amd64.deb" "${NEO_HASHES["intel-igc-opencl-2_2.41.5+22716_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-ocloc_26.35.39758.10-0_amd64.deb" \ - "intel-ocloc_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-ocloc_26.35.39758.10-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/intel-opencl-icd_26.35.39758.10-0_amd64.deb" \ - "intel-opencl-icd_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["intel-opencl-icd_26.35.39758.10-0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libigdgmm12_22.10.0_amd64.deb" \ - "libigdgmm12_22.10.0_amd64.deb" "${NEO_HASHES["libigdgmm12_22.10.0_amd64.deb"]}" -download_and_verify "https://github.com/intel/compute-runtime/releases/download/26.35.39758.10/libze-intel-gpu1_26.35.39758.10-0_amd64.deb" \ - "libze-intel-gpu1_26.35.39758.10-0_amd64.deb" "${NEO_HASHES["libze-intel-gpu1_26.35.39758.10-0_amd64.deb"]}" - -apt-get install -y ./*.deb +install_neo_packages cd / rm -rf "$TEMP_DIR" # ---- 4. add user ---- -print_substep "Añadiendo usuario a grupos render y video..." +print_substep "Adding user to render and video groups..." if [ -n "${SUDO_USER:-}" ]; then usermod -a -G render,video "$SUDO_USER" else