summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBala.FA <barumuga@redhat.com>2011-12-12 16:26:53 +0530
committerBala.FA <barumuga@redhat.com>2011-12-12 16:28:06 +0530
commit8f991af02abad977bb398e7d2a142ade44e48ce5 (patch)
treec9a11650fea666d736bdd3888ca8a53ce7acd75f
parent5fee99642f7726955dd1721e1b90a8865e9fe050 (diff)
Added dependency checking of python, perl, perl::RRDs, samba and libxml2.
Signed-off-by: Bala.FA <barumuga@redhat.com>
-rwxr-xr-xbuild/gmg-backend-install.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/build/gmg-backend-install.sh b/build/gmg-backend-install.sh
index dba8c92..5893f5d 100755
--- a/build/gmg-backend-install.sh
+++ b/build/gmg-backend-install.sh
@@ -43,6 +43,31 @@ function pre()
if [ ! -f /sbin/chkconfig ]; then
quit "/sbin/chkconfig not found!" ${CHKCONFIG_ERR}
fi
+
+ if which python 1>/dev/null 2>/dev/null; then
+ quit "python not found" -2
+ fi
+
+ if python -c 'import sys; sys.exit(sys.version_info >= (2,4,0) and sys.version_info < (3,0,0))'; then
+ python -c 'import sys; print "Python", sys.version'
+ quit "python version 2.4+ and less than 3.0 is required" -2
+ fi
+
+ if which perl 1>/dev/null 2>/dev/null; then
+ quit "perl not found" -2
+ fi
+
+ if ! perl -MRRDs -e 1 2>/dev/null; then
+ quit "perl::RRDs not found" -2
+ fi
+
+ if which smbd 1>/dev/null 2>/dev/null; then
+ quit "samba not found" -2
+ fi
+
+ if [ ! -f /usr/lib64/libxml2.so.2 ]; then
+ quit "libxml2 not found" -2
+ fi
}
function check_tar_gz()