aboutsummaryrefslogtreecommitdiffstats
path: root/net/freeradius2
diff options
context:
space:
mode:
authorsem <sem@FreeBSD.org>2007-01-23 20:35:52 +0800
committersem <sem@FreeBSD.org>2007-01-23 20:35:52 +0800
commit7d6aa26135df63d408fa1a02f71341f777d6b498 (patch)
tree17eb7e8b125184e211c650cb85017ce675e87d08 /net/freeradius2
parentb7c97ae19ff7718a86dbf5662ecba70d80905ef2 (diff)
downloadfreebsd-ports-gnome-7d6aa26135df63d408fa1a02f71341f777d6b498.tar.gz
freebsd-ports-gnome-7d6aa26135df63d408fa1a02f71341f777d6b498.tar.zst
freebsd-ports-gnome-7d6aa26135df63d408fa1a02f71341f777d6b498.zip
- Create default config files from *.sample and remove them if they did not
changed. (Requested by Alan DeKok of the FreeRADIUS Project.) - Add US mirror to MASTER_SITES. - Fix CFLAGS. - Tidy CONFIGURE_ARGS. - Remove EXAMPLESDIR references. It's using nowhere. - Pet portlint(1). PR: ports/108196 Submitted by: David Wood (maintainer)
Diffstat (limited to 'net/freeradius2')
-rw-r--r--net/freeradius2/Makefile26
-rw-r--r--net/freeradius2/pkg-plist6
2 files changed, 21 insertions, 11 deletions
diff --git a/net/freeradius2/Makefile b/net/freeradius2/Makefile
index 0445d3901ae1..3f6cf1a10793 100644
--- a/net/freeradius2/Makefile
+++ b/net/freeradius2/Makefile
@@ -12,6 +12,7 @@ CATEGORIES= net
MASTER_SITES= ftp://ftp.freeradius.org/pub/radius/ \
ftp://ftp.ntua.gr/pub/net/radius/freeradius/ \
ftp://ftp.uk.freeradius.org/pub/radius/ \
+ ftp://ftp.us.freeradius.org/pub/radius/ \
ftp://ftp.freeradius.org/pub/radius/old/ \
http://freeradius.portal-to-web.de/
@@ -29,7 +30,7 @@ USE_AUTOTOOLS= libltdl:15 libtool:15
USE_GMAKE= yes
USE_OPENSSL= yes
MAKE_ARGS+= LDFLAGS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}"
-CFLAGS+= -I${LOCALBASE}/include
+CFLAGS+= -I${LOCALBASE}/include -L${LOCALBASE}/lib
PLIST_SUB= PORTVERSION=${PORTVERSION}
@@ -45,17 +46,20 @@ OPTIONS= KERBEROS "With Kerberos support" off \
.include <bsd.port.pre.mk>
-CONFIGURE_ARGS= --prefix=${PREFIX} --quiet --with-logdir=${LOGDIR} \
+CONFIGURE_ARGS= --quiet \
+ --prefix=${PREFIX} \
--localstatedir=/var \
+ --mandir=${PREFIX}/man \
--with-system-libtool \
- --disable-ltdl-install \
--with-docdir=${DOCSDIR} \
- --mandir=${PREFIX}/man \
- --with-large-files --without-rlm_sql_unixodbc \
- --without-rlm_sql_oracle --without-rlm_sql_iodbc \
- --without-rlm_sql_db2 \
+ --with-logdir=${LOGDIR} \
+ --with-large-files \
--with-openssl-includes=${OPENSSLINC} \
- --with-openssl-libraries=${OPENSSLLIB}
+ --with-openssl-libraries=${OPENSSLLIB} \
+ --without-rlm_sql_unixodbc \
+ --without-rlm_sql_oracle \
+ --without-rlm_sql_iodbc \
+ --without-rlm_sql_db2
.if ${OSVERSION} < 500000 && ${OPENSSLBASE} == "/usr"
PLIST_SUB+= 4SSL="@comment "
@@ -206,9 +210,13 @@ post-patch:
.endif
post-install:
- @${MKDIR} ${PREFIX}/etc/raddb ${DATADIR} ${EXAMPLESDIR}
+ @${MKDIR} ${PREFIX}/etc/raddb ${DATADIR}
.for dict in ${DICTS}
${INSTALL_DATA} ${WRKSRC}/share/${dict} ${DATADIR}/${dict}
.endfor
+ for i in `${FIND} ${PREFIX}/etc/raddb -maxdepth 1 -regex '.*\.sample' -print \
+ | ${SED} -e 's/\.sample//g'`; do \
+ if [ ! -f $${i} ]; then ${CP} -p $${i}.sample $${i}; fi; \
+ done
.include <bsd.port.post.mk>
diff --git a/net/freeradius2/pkg-plist b/net/freeradius2/pkg-plist
index a2af4a0847f1..f21282f13565 100644
--- a/net/freeradius2/pkg-plist
+++ b/net/freeradius2/pkg-plist
@@ -12,6 +12,7 @@ bin/rlm_dbm_cat
bin/rlm_dbm_parser
bin/rlm_ippool_tool
bin/smbencrypt
+@unexec for i in `find %D/etc/raddb -maxdepth 1 -regex '.*\.sample' -print | sed -e 's/\.sample//g'`; do if [ -f ${i} ]; then if cmp -s ${i}.sample ${i}; then rm -f ${i}; fi; fi; done
etc/raddb/acct_users.sample
etc/raddb/attrs.sample
etc/raddb/certs/README
@@ -56,6 +57,7 @@ etc/raddb/snmp.conf.sample
etc/raddb/sql.conf.sample
etc/raddb/sqlippool.conf.sample
etc/raddb/users.sample
+@exec for i in `find %D/etc/raddb -maxdepth 1 -regex '.*\.sample' -print | sed -e 's/\.sample//g'`; do if [ ! -f ${i} ]; then cp -p ${i}.sample ${i}; fi; done
lib/libeap-%%PORTVERSION%%.la
lib/libeap-%%PORTVERSION%%.so
lib/libeap.a
@@ -492,7 +494,6 @@ sbin/rc.radiusd
%%DATADIR%%/dictionary.xedia
%%DATADIR%%/dictionary.xylan
%%DATADIR%%/dictionary.zyxel
-@dirrm %%EXAMPLESDIR%%
@dirrm %%DATADIR%%
%%PORTDOCS%%@dirrm %%DOCSDIR%%/rfc
%%PORTDOCS%%@dirrm %%DOCSDIR%%/examples
@@ -503,4 +504,5 @@ sbin/rc.radiusd
@exec chmod -R og= /var/log/raddb
@exec mkdir -p /var/run/radiusd
@unexec rm -fr /var/run/radiusd
-@unexec rmdir %D/etc/raddb 2> /dev/null || echo "You should remove %D/etc/raddb if you don't need it anymore."
+@dirrmtry etc/raddb
+@unexec if [ -d %D/etc/raddb ]; then echo "You should remove %D/etc/raddb if you don't need it anymore."; fi