mirror of
https://github.com/AdnanHodzic/auto-cpufreq.git
synced 2025-07-27 07:34:25 +02:00
Revamp logic to install libgirepository-2.0-dev or 1.0-dev
This commit is contained in:
parent
3898246f4b
commit
8870b62b17
@ -77,12 +77,19 @@ function tool_install {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if [ -f /etc/debian_version ]; then
|
if [ -f /etc/debian_version ]; then
|
||||||
VERSION=$(cat /etc/debian_version)
|
detected_distro "Debian based"
|
||||||
# VERSION="CSCS"
|
VERSION=$(cat /etc/debian_version)
|
||||||
if [[ "$VERSION" =~ ^12(\.[0-9]+)?$ || ("$VERSION" =~ ^[0-9]+$ && "$VERSION" -lt 12) ]]; then
|
|
||||||
LIB_GI_REPO="libgirepository1.0-dev"
|
# https://github.com/AdnanHodzic/auto-cpufreq/pull/826
|
||||||
else
|
# install necessary debian dependencies
|
||||||
LIB_GI_REPO="libgirepository-2.0-dev"
|
sudo apt update
|
||||||
|
|
||||||
|
if apt-cache show libgirepository-2.0-dev > /dev/null 2>&1; then
|
||||||
|
echo "Installing libgirepository-2.0-dev ..."
|
||||||
|
sudo apt install -y libgirepository-2.0-dev
|
||||||
|
else
|
||||||
|
echo "Installing libgirepository1.0-dev..."
|
||||||
|
sudo apt install -y libgirepository1.0-dev
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo $LIB_GI_REPO needs to be installed for version $VERSION
|
echo $LIB_GI_REPO needs to be installed for version $VERSION
|
||||||
|
Loading…
x
Reference in New Issue
Block a user