[Scripts] Detecting newest drivers on ubu20 (#7322)

* install_NEO_OCL_driver: Added detecting current driver via intel-opencl-icd package in case of newest one on ubuntu20. Added removing intel-opencl-icd package for ubuntu.

* install_NEO_OCL_driver: Fixed pattern for parsing driver version for newest drivers
This commit is contained in:
Artyom Anokhov
2021-09-01 15:00:24 +03:00
committed by GitHub
parent e3baff25a6
commit f14f28f32b

View File

@@ -329,6 +329,7 @@ _uninstall_user_mode_ubuntu()
echo Looking for previously installed user-mode driver...
PACKAGES=("intel-opencl"
"intel-opencl-icd"
"intel-ocloc"
"intel-gmmlib"
"intel-igc-core"
@@ -656,9 +657,12 @@ check_current_driver()
gfx_version=$(yum info intel-opencl | grep Version)
elif [[ $DISTRO == ubuntu ]]; then
gfx_version=$(apt show intel-opencl | grep Version)
if [[ -z "$gfx_version" ]]; then
gfx_version=$(apt show intel-opencl-icd | grep Version)
fi
fi
gfx_version="$(echo -e "${gfx_version}" | sed -e 's/^Version[[:space:]]*\:[[:space:]]*//')"
gfx_version="$(echo -e "${gfx_version}" | grep -Eo "[0-9]{2,3}\.[0-9]{2,3}\.[0-9]{3,6}")"
if [[ -z "$user_chosen_driver" ]]; then
check_specific_generation
fi