summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorJoerg Wunsch <joerg@FreeBSD.org>2005-04-08 09:32:25 +0000
committerJoerg Wunsch <joerg@FreeBSD.org>2005-04-08 09:32:25 +0000
commit0573e251a53635a919ad174d6910c97aa756b275 (patch)
treee9ad0536f7ea5e09cc54684288e62fb06d839fee /net
parenttaxipilot-0.9.1 < taxipilot-0.9.01_2, therefor PORTEPOCH bumped (diff)
Make LDAP support an option.
Previously, it was conditionally compiled into the package depending on whether ${LOCALBASE}/include/ldap.h was present in the host system, but without even considering to also conditionally modify the PLIST. This has been fixed now. Pointed out by: pointyhat's build log
Notes
Notes: svn path=/head/; revision=132745
Diffstat (limited to 'net')
-rw-r--r--net/openradius/Makefile15
-rw-r--r--net/openradius/pkg-plist2
-rw-r--r--net/openradius/scripts/configure2
3 files changed, 16 insertions, 3 deletions
diff --git a/net/openradius/Makefile b/net/openradius/Makefile
index 56ce26c935a7..8efd35869373 100644
--- a/net/openradius/Makefile
+++ b/net/openradius/Makefile
@@ -7,6 +7,7 @@
PORTNAME= openradius
PORTVERSION= 0.9.9
+PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= http://www.xs4all.nl/~evbergen/openradius/download/ \
http://www.mirrors.wiretapped.net/security/authentication/radius/openradius/
@@ -20,7 +21,19 @@ CC?= gcc
CXX?= g++
USE_GMAKE= yes
+OPTIONS= LDAP "With LDAP user database" off
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITH_LDAP)
+USE_OPENLDAP= YES
+PLIST_SUB+= LDAP=""
+SCRIPTS_ENV+= USE_LDAP=yes
+.else
+PLIST_SUB+= LDAP="@comment "
+.endif
+
post-install:
@${CAT} ${PKGMESSAGE}
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/net/openradius/pkg-plist b/net/openradius/pkg-plist
index eea128c0c813..a8e963f8580c 100644
--- a/net/openradius/pkg-plist
+++ b/net/openradius/pkg-plist
@@ -40,7 +40,7 @@ etc/openradius/subdicts/dict.ascend
lib/openradius/ascfile
lib/openradius/delay
lib/openradius/radclient
-lib/openradius/radldap
+%%LDAP%%lib/openradius/radldap
lib/openradius/radlogger
lib/openradius/radsql
lib/openradius/unixpasswd
diff --git a/net/openradius/scripts/configure b/net/openradius/scripts/configure
index 1e05a6e1a85a..9ea7457d1dd9 100644
--- a/net/openradius/scripts/configure
+++ b/net/openradius/scripts/configure
@@ -21,7 +21,7 @@ TGT_LIB += modules/delay/delay
TGT_LIB += modules/radsql/radsql
END
-if [ -f $LDAPINCLUDE/usr/local/include/ldap.h ]; then
+if [ x$USE_LDAP != x ]; then
cat >> Makefile << END
TGT_LIB += modules/radldap/radldap
CF_RADLDAP = -I$LDAPINCLUDE/usr/local/include