summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorDavid Sommerseth <dazo@users.sourceforge.net>2008-10-03 12:53:45 +0200
committerDavid Sommerseth <dazo@users.sourceforge.net>2008-10-03 12:53:45 +0200
commit75fc3665a86af37b1199128c3debe973f0cae8ea (patch)
tree21f451565a4317d8c023e329fcfd9710a31b8502 /configure
parent59b850f44e56263460db5e69b9f0a2fcebae4111 (diff)
downloadeurephia-75fc3665a86af37b1199128c3debe973f0cae8ea.tar.gz
eurephia-75fc3665a86af37b1199128c3debe973f0cae8ea.tar.xz
eurephia-75fc3665a86af37b1199128c3debe973f0cae8ea.zip
Made building more dynamic, improved parameter handling in configure and added more parameters
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure40
1 files changed, 40 insertions, 0 deletions
diff --git a/configure b/configure
index 84cccfc..59d0ab8 100755
--- a/configure
+++ b/configure
@@ -8,11 +8,16 @@ configure help for eurephia
--openvpn-src <path> | -s <path> -- OpenVPN source directory (needed for building)
--debug | -D -- Enable verbose debug logging
--show-secrets | -S -- Log passwords as clear text in log files
+ | (only available when debug is enabled)
+ --fw-iptables | -- Build iptables firewall module
+ --db-sqlite3 | -- Build SQLite3 database module
EOF
}
PARAMS=""
+DB=""
+FW=""
export OPENVPN_SRC_DIR=""
while [ ! -z "$1" ]; do
case $1 in
@@ -26,9 +31,19 @@ while [ ! -z "$1" ]; do
;;
-D|--debug)
PARAMS="${PARAMS} -DDEBUG=ON"
+ DEBUG_WARN=1
;;
-S|--show-secrets)
PARAMS="${PARAMS} -DSHOW_SECRETS=ON"
+ SECRETS_WARN=1
+ ;;
+ --fw-iptables)
+ PARAMS="${PARAMS} -DFW_IPTABLES=ON"
+ FW="iptables "
+ ;;
+ --db-sqlite3)
+ PARAMS="${PARAMS} -DSQLITE3=ON"
+ DB="SQLite3 "
;;
*)
echo "Unkown option: $1"
@@ -48,6 +63,31 @@ if [ -z ${OPENVPN_SRC_DIR} ]; then
exit 1;
fi
+if [ ${DB} = 0 ]; then
+ echo "You need to activate at least one database driver"
+ exit 1;
+fi
+
rm -f CMakeCache.txt
cmake . ${PARAMS}
+ec=$?
+if [ $ec = 0 ]; then
+ echo
+ echo
+ echo "eurephia will be built with support for: "
+ echo
+ echo " Database: ${DB}"
+ echo " Firewall: ${FW:-"None"}"
+ echo
+ if [ "$DEBUG_WARN" = 1 ]; then
+ echo
+ echo " ******* DEBUG is enabled. This might be a security issue *******"
+ echo
+ if [ "$SECRETS_WARN" = 1 ]; then
+ echo
+ echo " ******* SHOW_SECRETS is enabled. THIS WILL LOG PASSWORDS IN CLEAR TEXT IN LOG FILES *******"
+ echo
+ fi
+ fi
+fi
exit $?