[Openvas-commits] r6238 - trunk/tools
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Tue Dec 22 13:53:20 CET 2009
Author: felix
Date: 2009-12-22 13:53:19 +0100 (Tue, 22 Dec 2009)
New Revision: 6238
Added:
trunk/tools/build-all-svn-3-all.sh
Log:
Initial commit of slightly improved build script
Added: trunk/tools/build-all-svn-3-all.sh
===================================================================
--- trunk/tools/build-all-svn-3-all.sh 2009-12-22 10:00:02 UTC (rev 6237)
+++ trunk/tools/build-all-svn-3-all.sh 2009-12-22 12:53:19 UTC (rev 6238)
@@ -0,0 +1,54 @@
+#!/bin/sh
+# Author Felix Wolfsteller, heavily based on work by
+# (C) Vlatko Kosturjak. GPL v2
+
+OPENVASPREFIX=`date +%F`
+# Adjust to your needs:
+OPENVASPATH=/opt/openvas-svn-$OPENVASPREFIX
+
+echo "o Installing OpenVAS to $OPENVASPATH"
+
+# E.g. OpenVAS-Client configure needs to figure out the openvas-library version,
+# therefore set path and ld_library_path
+export LD_LIBRARY_PATH=$OPENVASPATH/lib:$LD_LIBRARY_PATH
+export PATH=$OPENVASPATH/bin:$PATH
+
+# Autoconf based
+build_ac_module()
+{
+ cd $1 && ./configure --prefix=$OPENVASPATH > ../configure-$i.log && make > ../make-$i.log && make install > ../make-install-$i.log && cd .. && return 0
+ return $1
+}
+
+# Cmake based
+build_cm_module()
+{
+ cd $1 && cmake -DCMAKE_INSTALL_PREFIX=$OPENVASPATH . > ../configure-$i.log && make > ../make-$i.log && make install > ../make-install-$i.log && cd .. && return 0
+ return $1
+}
+
+# (Mainly) autoconf based modules
+for i in openvas-libraries openvas-scanner openvas-client
+do
+ echo "o Installing OpenVAS module: $i"
+ if build_ac_module $i ; then
+ echo " - succes"
+ else
+ echo " - failed"
+ break
+ fi
+done
+
+# Cmake based modules
+for i in openvas-manager openvas-administrator
+do
+ echo "o Installing OpenVAS module: $i"
+ if build_cm_module $i ; then
+ echo " - succes"
+ else
+ echo " - failed"
+ break
+ fi
+done
+
+echo "o Finished installation of OpenVAS to $OPENVASPATH"
More information about the Openvas-commits
mailing list