diff options
Diffstat (limited to 'configure')
| -rwxr-xr-x | configure | 35 | 
1 files changed, 35 insertions, 0 deletions
| @@ -27,6 +27,7 @@ yahoo=1  debug=0  strip=1  ipv6=1 +ldb=auto  ssl=auto  arch=`uname -s` @@ -63,6 +64,8 @@ Option		Description				Default  --ipv6=0/1	IPv6 socket support			$ipv6 +--ldb=0/1/auto	LDB support				$ldb +  --ssl=...	SSL library to use (gnutls, nss, openssl, bogus, auto)  							$ssl  EOF @@ -220,6 +223,20 @@ EOF  	fi;  } +detect_ldb() +{ +	if $PKG_CONFIG --version > /dev/null 2>/dev/null && $PKG_CONFIG ldb; then +		cat<<EOF>>Makefile.settings +EFLAGS+=`$PKG_CONFIG --libs ldb` +CFLAGS+=`$PKG_CONFIG --cflags ldb` +EOF +		ldb=1 +		ret=1 +	else +		ret=0 +	fi +} +  if [ "$msn" = 1 -o "$jabber" = 1 ]; then  	if [ "$ssl" = "auto" ]; then  		detect_gnutls @@ -280,6 +297,18 @@ if [ "$msn" = 1 -o "$jabber" = 1 ]; then  	echo 'SSL_CLIENT=ssl_'$ssl'.o' >> Makefile.settings  fi +if [ "$ldb" = "auto" ]; then +	detect_ldb +fi + +if [ "$ldb" = 0 ]; then +	echo "LDB_OBJ=\# no ldb" >> Makefile.settings +	echo "#undef LDB" >> config.h +elif [ "$ldb" = 1 ]; then +	echo "#define LDB 1" >> config.h +	echo "LDB_OBJ=storage_ldb.o" >> Makefile.settings +fi +  if [ "$strip" = 0 ]; then  	echo "STRIP=\# skip strip" >> Makefile.settings;  else @@ -430,3 +459,9 @@ if [ -n "$protocols" ]; then  else  	echo '  Building without IM-protocol support. We wish you a lot of fun...';  fi + +if [ "$ldb" = "0" ]; then +	echo "  LDB storage backend disabled." +else +	echo "  LDB storage backend enabled." +fi | 
