summaryrefslogtreecommitdiffstats
path: root/ci/build.sh
diff options
context:
space:
mode:
authorTim Rozet <trozet@redhat.com>2016-05-24 17:14:36 -0400
committerTim Rozet <trozet@redhat.com>2016-05-25 14:05:26 -0400
commit2370aea5cb854569722897dcb37341841842e873 (patch)
tree73e9d45fe2c5115bf2a701d9f2a63ee7ef7923a4 /ci/build.sh
parent5fec80057dbd799d52a4c1ff2f35a1c8cc5ad6ea (diff)
Fixes nic template missing in spec and error catching
Issue where jinja 2 templates were missing from spec file. Also adds error checking to make sure the nic templates were correctly generated. There was an error with dependencies missing on the build server - this patch includes a fix to make sure it is installed before trying to make. Change-Id: I7989ccf297a4e0d81326cccc06b2132018e7d8ae Signed-off-by: Tim Rozet <trozet@redhat.com>
Diffstat (limited to 'ci/build.sh')
-rwxr-xr-xci/build.sh11
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