Skip to content

Commit

Permalink
installts: Fix test suite installation issues.
Browse files Browse the repository at this point in the history
* Apply unmerged patch to fix SIPP compilation
  and python3 detection in Asterisk test suite
* Abort if test suite installation exits nonzero
* Perform shallow clones of repositories to speed
  up download
  • Loading branch information
InterLinked1 committed Apr 8, 2024
1 parent 67fe8a4 commit 6fe10b1
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions phreaknet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1106,7 +1106,16 @@ install_testsuite_itself() {
fi
cd testsuite

# Apply patch if needed to fix SIPP compilation and python3 detection
grep "3.5.2" contrib/scripts/install_prereq
$WGET https://patch-diff.githubusercontent.com/raw/asterisk/testsuite/pull/48.patch
git apply 48.patch

./contrib/scripts/install_prereq install
if [ $? -ne 0 ]; then
die "Failed to install test suite"
fi

# In theory, the below is not necessary:
pip3 install pyyaml
pip3 install twisted
Expand Down Expand Up @@ -1148,6 +1157,7 @@ install_testsuite() { # $1 = $FORCE_INSTALL
return 1
fi
cd $AST_SOURCE_PARENT_DIR/$AST_SRC_DIR
# Ensure we're compiled with dev mode, or recompile in dev mode if needed
configure_devmode
make
make install
Expand Down Expand Up @@ -2343,7 +2353,7 @@ get_source() {
git reset --hard origin/master
cd ..
else
git clone "https://github.com/asterisk/asterisk"
git clone --depth=1 "https://github.com/asterisk/asterisk"
mv asterisk asterisk-git
fi
if [ $? -ne 0 ]; then
Expand All @@ -2367,7 +2377,7 @@ get_source() {
exit 1
fi
if [ "$CHAN_SCCP" = "1" ]; then
git clone https://github.com/chan-sccp/chan-sccp.git chan-sccp
git clone --depth=1 https://github.com/chan-sccp/chan-sccp.git chan-sccp
fi

if [ "$AST_ALT_VER" = "git" ]; then
Expand Down

0 comments on commit 6fe10b1

Please sign in to comment.