forked from norman/fusionpbx-install.sh-github-mirror
Use one condition to overwrite the branch
Simplifies the code by removing multiple conditions for the trixie codename
This commit is contained in:
16
debian/resources/switch/source-release.sh
vendored
16
debian/resources/switch/source-release.sh
vendored
@@ -35,6 +35,12 @@ if [ ."$os_codename" = ."trixie" ]; then
|
|||||||
apt install -y python3-distutils-extra plocate
|
apt install -y python3-distutils-extra plocate
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#use master branch for Debian 13 for now
|
||||||
|
if [ ."$os_codename" = ."trixie" ]; then
|
||||||
|
switch_version=1.10.13
|
||||||
|
switch_branch=master
|
||||||
|
fi
|
||||||
|
|
||||||
# additional dependencies
|
# additional dependencies
|
||||||
apt install -y sqlite3 unzip
|
apt install -y sqlite3 unzip
|
||||||
|
|
||||||
@@ -42,7 +48,7 @@ apt install -y sqlite3 unzip
|
|||||||
CWD=$(pwd)
|
CWD=$(pwd)
|
||||||
|
|
||||||
#install the following dependencies if the switch version is greater than 1.10.0
|
#install the following dependencies if the switch version is greater than 1.10.0
|
||||||
if [ ."$switch_version" = ."master" ] || [ $(echo "$switch_version" | tr -d '.') -gt 1100 ] || [ ."$os_codename" = ."trixie" ]; then
|
if [ ."$switch_version" = ."master" ] || [ $(echo "$switch_version" | tr -d '.') -gt 1100 ]; then
|
||||||
|
|
||||||
# libks build-requirements
|
# libks build-requirements
|
||||||
apt install -y cmake uuid-dev
|
apt install -y cmake uuid-dev
|
||||||
@@ -60,7 +66,7 @@ if [ ."$switch_version" = ."master" ] || [ $(echo "$switch_version" | tr -d '.')
|
|||||||
|
|
||||||
# sofia-sip
|
# sofia-sip
|
||||||
cd /usr/src
|
cd /usr/src
|
||||||
if [ ."$sofia_version" = ."master" ] || [ ."$os_codename" = ."trixie" ]; then
|
if [ ."$sofia_version" = ."master" ]; then
|
||||||
git clone https://github.com/freeswitch/sofia-sip.git sofia-sip
|
git clone https://github.com/freeswitch/sofia-sip.git sofia-sip
|
||||||
cd sofia-sip
|
cd sofia-sip
|
||||||
else
|
else
|
||||||
@@ -77,7 +83,7 @@ if [ ."$switch_version" = ."master" ] || [ $(echo "$switch_version" | tr -d '.')
|
|||||||
cd /usr/src
|
cd /usr/src
|
||||||
git clone https://github.com/freeswitch/spandsp.git spandsp
|
git clone https://github.com/freeswitch/spandsp.git spandsp
|
||||||
cd spandsp
|
cd spandsp
|
||||||
if [ ."$sofia_version" != ."master" ] && [ ."$os_codename" != ."trixie" ] && [ ."$switch_branch" != ."master" ]; then
|
if [ ."$sofia_version" != ."master" ] && [ ."$switch_branch" != ."master" ]; then
|
||||||
git reset --hard 0d2e6ac65e0e8f53d652665a743015a88bf048d4
|
git reset --hard 0d2e6ac65e0e8f53d652665a743015a88bf048d4
|
||||||
fi
|
fi
|
||||||
#/usr/bin/sed -i 's/AC_PREREQ(\[2\.71\])/AC_PREREQ([2.69])/g' /usr/src/spandsp/configure.ac
|
#/usr/bin/sed -i 's/AC_PREREQ(\[2\.71\])/AC_PREREQ([2.69])/g' /usr/src/spandsp/configure.ac
|
||||||
@@ -91,7 +97,7 @@ fi
|
|||||||
cd /usr/src
|
cd /usr/src
|
||||||
|
|
||||||
#check for master
|
#check for master
|
||||||
if [ ."$os_codename" = ."trixie" ] || [ ."$switch_branch" = ."master" ]; then
|
if [ ."$switch_branch" = ."master" ]; then
|
||||||
#master branch
|
#master branch
|
||||||
echo "Using version master"
|
echo "Using version master"
|
||||||
rm -r /usr/src/freeswitch
|
rm -r /usr/src/freeswitch
|
||||||
@@ -107,7 +113,7 @@ if [ ."$os_codename" = ."trixie" ] || [ ."$switch_branch" = ."master" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
#check for stable release
|
#check for stable release
|
||||||
if [ ."$switch_branch" != ."master" ] && [ ."$os_codename" != ."trixie" ] && [ ."$switch_branch" = ."stable" ]; then
|
if [ ."$switch_branch" != ."master" ] && [ ."$switch_branch" = ."stable" ]; then
|
||||||
echo "Using version $switch_version"
|
echo "Using version $switch_version"
|
||||||
#1.8 and older
|
#1.8 and older
|
||||||
if [ $(echo "$switch_version" | tr -d '.') -lt 1100 ]; then
|
if [ $(echo "$switch_version" | tr -d '.') -lt 1100 ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user