Skip to content

Commit 0618375

Browse files
Markos Chandrasjuliakreger
authored andcommitted
imagebuild: tinyipa: Make the install-deps.sh SUSE aware
Add zypper support in the install-deps.sh script so tinyipa can be built on SUSE distributions. Change-Id: Ie7ac36a9cab3dba825357ccd1e58290873335a68
1 parent fd7f10b commit 0618375

2 files changed

Lines changed: 16 additions & 6 deletions

File tree

‎imagebuild/tinyipa/install-deps.sh‎

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
#!/bin/bash
22

3-
PACKAGES="wget python-pip unzip sudo gawk squashfs-tools"
3+
COMMON_PACKAGES="wget python-pip unzip sudo gawk"
4+
APT_PACKAGES="${COMMON_PACKAGES} squashfs-tools"
5+
YUM_PACKAGES="${COMMON_PACKAGES} squashfs-tools"
6+
ZYPPER_PACKAGES="${COMMON_PACKAGES} squashfs"
47

58
echo "Installing dependencies:"
69

7-
if [ -x "/usr/bin/apt-get" ]; then
10+
# first zypper in case zypper-aptitude is installed
11+
if [ -x "/usr/bin/zypper" ]; then
12+
sudo -E zypper -n install -l ${ZYPPER_PACKAGES}
13+
elif [ -x "/usr/bin/apt-get" ]; then
814
sudo -E apt-get update
9-
sudo -E apt-get install -y $PACKAGES
15+
sudo -E apt-get install -y ${APT_PACKAGES}
1016
elif [ -x "/usr/bin/dnf" ]; then
11-
sudo -E dnf install -y $PACKAGES
17+
sudo -E dnf install -y ${YUM_PACKAGES}
1218
elif [ -x "/usr/bin/yum" ]; then
13-
sudo -E yum install -y $PACKAGES
19+
sudo -E yum install -y ${YUM_PACKAGES}
1420
else
15-
echo "No supported package manager installed on system. Supported: apt, yum, dnf"
21+
echo "No supported package manager installed on system. Supported: apt, yum, dnf, zypper"
1622
exit 1
1723
fi
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
features:
3+
- Support for zypper has been added to the TinyIPA install-deps script
4+
in order to support building TinyIPA on SUSE.

0 commit comments

Comments
 (0)