File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed
Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 22env
33
44
5+ if [ -f /etc/os-release ]; then
6+ . /etc/os-release
7+ if [[ " $ID " == " ubuntu" || " $ID_LIKE " == " debian" ]]; then
8+ PACKAGE_MANAGER=" apt"
9+ elif [[ " $ID " == " rhel" || " $ID_LIKE " == " rhel fedora rocky centos" ]]; then
10+ PACKAGE_MANAGER=" yum"
11+ else
12+ echo " Unsupported OS: $ID "
13+ exit 1
14+ fi
15+ else
16+ echo " /etc/os-release not found. Unable to determine OS."
17+ exit 1
18+ fi
19+
20+ echo " Using package manager: $PACKAGE_MANAGER "
21+
22+ if [ " $PACKAGE_MANAGER " == " apt" ]; then
23+ apt update && apt install -y blas lapack
24+ elif [ " $PACKAGE_MANAGER " == " yum" ]; then
25+ yum install -y blas lapack
26+ fi
27+
528# The or_die function run the passed command line and
629# exits the program in case of non zero error code
730function or_die () {
You can’t perform that action at this time.
0 commit comments