diff options
author | Tim Rozet <trozet@redhat.com> | 2016-05-25 21:06:36 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@172.30.200.206> | 2016-05-25 21:06:36 +0000 |
commit | 6b5a9c96809acfbb516918db7ab3ba36eb7fda92 (patch) | |
tree | ac410182ddbabaee2db7dcaef0d66417a8787b92 /ci/build.sh | |
parent | 217a97a33db42da90e7f62231b74efa3ef120131 (diff) | |
parent | 2370aea5cb854569722897dcb37341841842e873 (diff) |
Merge "Fixes nic template missing in spec and error catching"
Diffstat (limited to 'ci/build.sh')
-rwxr-xr-x | ci/build.sh | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ci/build.sh b/ci/build.sh index 7e080bed..e6870558 100755 --- a/ci/build.sh +++ b/ci/build.sh @@ -35,6 +35,7 @@ CACHE_DEST="" CACHE_DIR="cache" CACHE_NAME="apex-cache" MAKE_TARGETS="images" +REQUIRED_PKGS="rpm-build python-docutils" parse_cmdline() { while [ "${1:0:1}" = "-" ] @@ -82,6 +83,16 @@ run_make() { parse_cmdline "$@" +# Install build dependencies +for pkg in $REQUIRED_PKGS; do + if ! rpm -q $pkg > /dev/null; then + if ! sudo yum -y install $pkg > /dev/null; then + echo "Required package $pkg missing and installation failed." + exit 1 + fi + fi +done + if [ -n "$RELEASE" ]; then MAKE_ARGS+="RELEASE=$RELEASE "; fi # Get the Old Cache |