Skip to content
Snippets Groups Projects
Commit dbf5ff6e authored by Alexander Traud's avatar Alexander Traud
Browse files

install_prereq: Add Arch Linux.

ASTERISK-27738

Change-Id: I7ca620e3c4dfb4b064a19382c4915aeb42a2a09f
parent 607baba9
Branches
Tags
No related merge requests found
...@@ -66,6 +66,22 @@ PACKAGES_SUSE="$PACKAGES_SUSE wget subversion" ...@@ -66,6 +66,22 @@ PACKAGES_SUSE="$PACKAGES_SUSE wget subversion"
# Asterisk: for ./configure --with-pjproject-bundled: # Asterisk: for ./configure --with-pjproject-bundled:
PACKAGES_SUSE="$PACKAGES_SUSE bzip2 patch python-devel" PACKAGES_SUSE="$PACKAGES_SUSE bzip2 patch python-devel"
# Basic build system:
PACKAGES_ARCH="make gcc pkg-config"
# Asterisk: basic requirements:
PACKAGES_ARCH="$PACKAGES_ARCH libedit jansson libutil-linux libxml2 sqlite"
# Asterisk: for addons:
PACKAGES_ARCH="$PACKAGES_ARCH speex speexdsp libogg libvorbis alsa-lib portaudio curl xmlstarlet bison flex"
PACKAGES_ARCH="$PACKAGES_ARCH postgresql-libs unixodbc libtool neon gmime lua uriparser libxslt openssl"
PACKAGES_ARCH="$PACKAGES_ARCH libmariadbclient bluez-libs radcli freetds bash"
PACKAGES_ARCH="$PACKAGES_ARCH net-snmp libnewt popt libical spandsp"
PACKAGES_ARCH="$PACKAGES_ARCH c-client binutils libsrtp gsm doxygen graphviz zlib libldap"
PACKAGES_ARCH="$PACKAGES_ARCH fftw libsndfile unbound"
# Asterisk: for the unpackaged below:
PACKAGES_ARCH="$PACKAGES_ARCH wget subversion"
# Asterisk: for ./configure --with-pjproject-bundled:
PACKAGES_ARCH="$PACKAGES_ARCH bzip2 patch python2"
# Basic build system: # Basic build system:
PACKAGES_NBSD="gmake pkg-config" PACKAGES_NBSD="gmake pkg-config"
# Asterisk: basic requirements: # Asterisk: basic requirements:
...@@ -163,6 +179,15 @@ check_installed_rpms() { ...@@ -163,6 +179,15 @@ check_installed_rpms() {
done done
} }
check_installed_pacman() {
for pack in "$@"
do
if ! pacman -Q --explicit $pack >/dev/null 2>/dev/null
then echo $pack
fi
done
}
check_installed_pkgs() { check_installed_pkgs() {
for pack in "$@" for pack in "$@"
do do
...@@ -208,6 +233,13 @@ handle_rh() { ...@@ -208,6 +233,13 @@ handle_rh() {
fi fi
} }
handle_arch() {
extra_packs=`check_installed_pacman $PACKAGES_ARCH`
if [ x"$extra_packs" != "x" ] ; then
$testcmd pacman -S --asexplicit --noconfirm $extra_packs
fi
}
handle_nbsd() { handle_nbsd() {
extra_packs=`check_installed_pkgs $PACKAGES_NBSD` extra_packs=`check_installed_pkgs $PACKAGES_NBSD`
if [ x"$extra_packs" != "x" ] ; then if [ x"$extra_packs" != "x" ] ; then
...@@ -334,6 +366,10 @@ elif [ -f /etc/SuSE-release -o -f /etc/novell-release ]; then ...@@ -334,6 +366,10 @@ elif [ -f /etc/SuSE-release -o -f /etc/novell-release ]; then
handle_SUSE handle_SUSE
elif [ -f /etc/os-release ] && . /etc/os-release && [ "$ID" = "opensuse" ]; then elif [ -f /etc/os-release ] && . /etc/os-release && [ "$ID" = "opensuse" ]; then
handle_SUSE handle_SUSE
elif [ -r /etc/arch-release ]; then
handle_arch
elif [ -f /etc/os-release ] && . /etc/os-release && [ "$ID_LIKE" = "archlinux" ]; then
handle_arch # $ID=arch
elif [ "$OS" = 'NetBSD' ]; then elif [ "$OS" = 'NetBSD' ]; then
handle_nbsd handle_nbsd
elif [ "$OS" = 'OpenBSD' ]; then elif [ "$OS" = 'OpenBSD' ]; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment