diff options
author | beech <beech@FreeBSD.org> | 2007-08-31 02:33:30 +0800 |
---|---|---|
committer | beech <beech@FreeBSD.org> | 2007-08-31 02:33:30 +0800 |
commit | 0761274d27cf3a4bd4a133368a0a5a0928ec2751 (patch) | |
tree | 86c256f7adf381103a93bb5f7c9f2f68441ab4a7 /ftp/proftpd | |
parent | 84bde49dfca178051924b8e3dfa7c4c2b96585f2 (diff) | |
download | freebsd-ports-gnome-0761274d27cf3a4bd4a133368a0a5a0928ec2751.tar.gz freebsd-ports-gnome-0761274d27cf3a4bd4a133368a0a5a0928ec2751.tar.zst freebsd-ports-gnome-0761274d27cf3a4bd4a133368a0a5a0928ec2751.zip |
- Add support for clamav
- Fix ldap support
PR: ports/115752, ports/115867
Submitted by: Vladimir Korkodinov <viper@perm.raid.ru> (ports/115752),
Thomas Vogt <thomas@bsdunix.ch> (ports/115867)
Approved by: sat (mantor)
Diffstat (limited to 'ftp/proftpd')
-rw-r--r-- | ftp/proftpd/Makefile | 42 | ||||
-rw-r--r-- | ftp/proftpd/distinfo | 3 | ||||
-rw-r--r-- | ftp/proftpd/files/extra-patch-contrib-mod_ldap.c | 51 | ||||
-rw-r--r-- | ftp/proftpd/files/extra_patch-ldap-tls-mod_ldap.c | 11 |
4 files changed, 85 insertions, 22 deletions
diff --git a/ftp/proftpd/Makefile b/ftp/proftpd/Makefile index 55f1916c0e67..8d7fdf937321 100644 --- a/ftp/proftpd/Makefile +++ b/ftp/proftpd/Makefile @@ -7,7 +7,7 @@ PORTNAME= proftpd DISTVERSION= 1.3.1rc3 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= ftp MASTER_SITES= ftp://ftp.proftpd.org/distrib/source/ \ ftp://ftp.fastorama.com/mirrors/ftp.proftpd.org/distrib/source/ \ @@ -15,7 +15,9 @@ MASTER_SITES= ftp://ftp.proftpd.org/distrib/source/ \ ftp://spirit.bentel.sk/mirrors/Proftpd/distrib/source/ \ ftp://proftpd.networkedsystems.co.uk/distrib/source/ \ http://mirrors.ibiblio.org/pub/mirrors/proftpd/distrib/source/ \ - http://www.mirrorservice.org/sites/ftp.proftpd.org/distrib/source/ + http://www.mirrorservice.org/sites/ftp.proftpd.org/distrib/source/ \ + CENKES:clam +DISTFILES= ${DISTNAME}${EXTRACT_SUFX} MAINTAINER?= beech@FreeBSD.org COMMENT?= Highly configurable ftp daemon @@ -53,7 +55,7 @@ CONFIGURE_ARGS= --localstatedir=/var/run \ OPTIONS= IPV6 "Use IPv6" off \ LDAP "Use LDAP" off \ - LDAP_TLS "Use LDAP TLS (Requires LDAP)" off\ + LDAP_TLS "Use LDAP TLS (Requires LDAP, OPENSSL)" off\ MYSQL "Use MySQL" off \ PGSQL "Use Postgres" off \ OPENSSL "Include mod_tls" off \ @@ -61,16 +63,17 @@ OPTIONS= IPV6 "Use IPv6" off \ IFSESSION "Include mod_ifsession" on \ README "Include mod_readme" on \ RATIO "Include mod_ratio" on \ - CTRLS "include controls" off \ + CTRLS "Include controls" off \ REWRITE "Include mod_rewrite" on \ WRAP "Include mod_wrap2" on \ - WRAP_FILE "include mod_wrap2_file" off \ - WRAP_SQL "include mod_wrap2_sql" off \ + WRAP_FILE "Include mod_wrap2_file" off \ + WRAP_SQL "Include mod_wrap2_sql" off \ RADIUS "Include mod_radius" off \ QUOTATAB_RADIUS "include mod_quotatab_radius" off \ - BAN "include mod_ban (Requires CTRLS)" off \ + BAN "Include mod_ban (Requires CTRLS)" off \ NLS "Use nls (builds mod_lang)" off \ - CYRFIX "Use patch for fix cyrillic encoding" off + CYRFIX "Patch to fix cyrillic encoding" off \ + CLAMAV "Include mod_clamav " off MODULES?= LIBDIRS?= @@ -160,6 +163,7 @@ USE_OPENLDAP= yes MODULES:=${MODULES}:mod_ldap INCLUDEDIRS:=${INCLUDEDIRS}:${LOCALBASE}/include LIBDIRS:=${LIBDIRS}:${LOCALBASE}/lib +EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-contrib-mod_ldap.c .endif .if defined(WITH_MYSQL) @@ -186,9 +190,6 @@ CFLAGS+= -DHAVE_OPENSSL .include <${PORTSDIR}/Mk/bsd.openssl.mk> PROFTPD_LIBS+= -lssl -lcrypto -L${LOCALBASE}/lib MODULES:=${MODULES}:mod_tls -.if defined(WITH_LDAP_TLS) -EXTRA_PATCHES+= ${FILESDIR}/extra_patch-ldap-tls-mod_ldap.c -.endif .endif .if defined(WITH_CTRLS) @@ -210,6 +211,16 @@ MODULES:=${MODULES}:mod_quotatab_sql .endif .endif +.if defined(WITH_CLAMAV) +#http://www.uglyboxindustries.com/mod_clamav_new.c +DISTFILES+= mod_clamav-0.5.tar.bz2:clam +USE_CLAMAV= yes +MODULES:=${MODULES}:mod_clamav +LIB_DEPENDS+= clamav.2:${PORTSDIR}/security/clamav +INCLUDEDIRS:=${INCLUDEDIRS}:${LOCALBASE}/include +LIBDIRS:=${LIBDIRS}:${LOCALBASE}/lib +.endif + # mod_ifsession should be the last item in the modules list .if !defined(WITHOUT_IFSESSION) MODULES:=${MODULES}:mod_ifsession @@ -232,10 +243,19 @@ CONFIGURE_ARGS+= --with-libraries=${LIBDIRS} MODULES!=${ECHO} ${MODULES} | ${SED} -e 's,^:,,' -e 's,:$$,,' +post-extract: +.if defined(WITH_CLAMAV) + @${MV} ${WRKDIR}/mod_clamav_new.c ${WRKSRC}/modules/mod_clamav.c +.endif + post-patch: .if defined(WITH_NLS) @${REINPLACE_CMD} -e 's|-lsupp|-lsupp -lintl|g' ${WRKSRC}/Makefile.in .endif +.if defined(WITH_LDAP_TLS) + @${REINPLACE_CMD} -e 's:/\* #define USE_LDAP_TLS \*/:#define USE_LDAP_TLS:' \ + ${WRKSRC}/contrib/mod_ldap.c +.endif @${REINPLACE_CMD} -e 's|proftpd\.conf|proftpd.conf.sample|g' ${WRKSRC}/Makefile.in pre-configure: diff --git a/ftp/proftpd/distinfo b/ftp/proftpd/distinfo index 906cb56d40c5..cbe9f53832c0 100644 --- a/ftp/proftpd/distinfo +++ b/ftp/proftpd/distinfo @@ -1,3 +1,6 @@ MD5 (proftpd-1.3.1rc3.tar.bz2) = 485af3aee9ecebfeae1ae2003250a3a9 SHA256 (proftpd-1.3.1rc3.tar.bz2) = 9bad65ea4ddca40547ca6bb1aa337c7d4ae54752bb9f5fc76124a8c4535daefd SIZE (proftpd-1.3.1rc3.tar.bz2) = 1538700 +MD5 (mod_clamav-0.5.tar.bz2) = a098b630db1aa4ce02d77be84c21e59d +SHA256 (mod_clamav-0.5.tar.bz2) = badab5d0577439e4de4a4d8fa6d1035da4884cc5b8e5569057816da4ced9667f +SIZE (mod_clamav-0.5.tar.bz2) = 3027 diff --git a/ftp/proftpd/files/extra-patch-contrib-mod_ldap.c b/ftp/proftpd/files/extra-patch-contrib-mod_ldap.c new file mode 100644 index 000000000000..ef8660fc7b76 --- /dev/null +++ b/ftp/proftpd/files/extra-patch-contrib-mod_ldap.c @@ -0,0 +1,51 @@ +---contrib/mod_ldap.c.orig 2007-07-02 15:20:31.000000000 -0800 ++++ contrib/mod_ldap.c 2007-08-27 13:48:11.000000000 -0800 +@@ -22,7 +22,7 @@ + */ + + /* +- * mod_ldap v2.8.17-20070701 ++ * mod_ldap v2.8.17 + * + * Thanks for patches go to (in alphabetical order): + * +@@ -48,7 +48,7 @@ + * LDAPDefaultAuthScheme + * + * +- * $Id: mod_ldap.c,v 1.54 2007/07/02 23:20:31 jwm Exp $ ++ * $Id: mod_ldap.c,v 1.57 2007/08/22 02:00:06 jwm Exp $ + * $Libraries: -lldap -llber$ + */ + +@@ -70,7 +70,7 @@ + #include "conf.h" + #include "privs.h" + +-#define MOD_LDAP_VERSION "mod_ldap/2.8.17-20070701" ++#define MOD_LDAP_VERSION "mod_ldap/2.8.17" + + #if PROFTPD_VERSION_NUMBER < 0x0001021002 + # error MOD_LDAP_VERSION " requires ProFTPD 1.2.10rc2 or later" +@@ -2245,8 +2245,8 @@ + * ldap_init() will connect to the LDAP SDK's default. + */ + if ((c = find_config(main_server->conf, CONF_PARAM, "LDAPServer", FALSE)) != NULL) { +- if (strcmp(c->argv[1], "url") == 0) { +- url = c->argv[2]; ++ if (strcmp(c->argv[0], "url") == 0) { ++ url = c->argv[1]; + if (url) { + #ifdef LDAP_OPT_X_TLS_HARD + if (strcmp(url->lud_scheme, "ldaps") == 0) { +@@ -2269,8 +2269,8 @@ + * by other/future callers. + */ + } +- } else if (strcmp(c->argv[1], "host") == 0) { +- ldap_server = c->argv[2]; ++ } else if (strcmp(c->argv[0], "host") == 0) { ++ ldap_server = c->argv[1]; + } else { + /* This should never happen, since the configuration handler for + * LDAPServer only passes url or host, but we'll be defensive. diff --git a/ftp/proftpd/files/extra_patch-ldap-tls-mod_ldap.c b/ftp/proftpd/files/extra_patch-ldap-tls-mod_ldap.c deleted file mode 100644 index b4a9e5427f59..000000000000 --- a/ftp/proftpd/files/extra_patch-ldap-tls-mod_ldap.c +++ /dev/null @@ -1,11 +0,0 @@ ---- contrib/mod_ldap.c.orig Thu Oct 19 18:18:07 2006 -+++ contrib/mod_ldap.c Fri Dec 15 11:01:21 2006 -@@ -60,7 +60,7 @@ - * after connecting to the LDAP server. If TLS cannot be enabled, the LDAP - * connection will fail. - */ --/* #define USE_LDAP_TLS */ -+#define USE_LDAP_TLS */ - - /* - * If you have to edit anything below this line, it's a bug. Report it |