Bug 187860 - [patch] ftp/proftpd: prefer libc iconv
Summary: [patch] ftp/proftpd: prefer libc iconv
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Martin Matuska
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-23 21:40 UTC by Tijl Coosemans
Modified: 2014-03-27 23:34 UTC (History)
0 users

See Also:


Attachments
proftpd.patch (1.73 KB, patch)
2014-03-23 21:40 UTC, Tijl Coosemans
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tijl Coosemans freebsd_committer freebsd_triage 2014-03-23 21:40:00 UTC
- Add DOCS option.
- When the NLS option is enabled the configure script looks for iconv_open()
  and libiconv_open() functions in libiconv before trying libc.  This means
  that on FreeBSD 10 proftpd depends on converters/libiconv when it is
  installed but it should use iconv from libc instead.
  To fix this add ac_cv_lib_iconv_iconv_open=no and
  ac_cv_lib_iconv_libiconv_open=no to CONFIGURE_ARGS to bypass those
  configure tests when ICONV_LIB is empty.
- Remove references to -lintl.  The configure script detects it correctly.

Redports: https://redports.org/buildarchive/20140323211200-59723/
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2014-03-23 21:40:04 UTC
Responsible Changed
From-To: freebsd-ports-bugs->mm

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer freebsd_triage 2014-03-27 23:26:08 UTC
Author: mm
Date: Thu Mar 27 23:26:04 2014
New Revision: 349373
URL: http://svnweb.freebsd.org/changeset/ports/349373
QAT: https://qat.redports.org/buildarchive/r349373/

Log:
  - Add DOCS option.
  - When the NLS option is enabled the configure script looks for iconv_open()
  and libiconv_open() functions in libiconv before trying libc. This means
  that on FreeBSD 10 proftpd depends on converters/libiconv when it is
  installed but it should use iconv from libc instead.
  To fix this add ac_cv_lib_iconv_iconv_open=no and
  ac_cv_lib_iconv_libiconv_open=no to CONFIGURE_ARGS to bypass those
  configure tests when ICONV_LIB is empty.
  - Remove references to -lintl. The configure script detects it correctly.
  
  PR:		ports/187860
  Submitted by:	tijl@FreeBSD.org

Modified:
  head/ftp/proftpd/Makefile

Modified: head/ftp/proftpd/Makefile
==============================================================================
--- head/ftp/proftpd/Makefile	Thu Mar 27 23:21:07 2014	(r349372)
+++ head/ftp/proftpd/Makefile	Thu Mar 27 23:26:04 2014	(r349373)
@@ -5,7 +5,7 @@ PORTNAME?=	proftpd
 .if !defined(DISTVERSION)
 PORTVERSION?=	${PROFTPD_VERSION}
 .endif
-PORTREVISION?=	3
+PORTREVISION?=	4
 CATEGORIES?=	ftp
 MASTER_SITES=	ftp://ftp.proftpd.org/distrib/source/ \
 		https://github.com/downloads/proftpd/proftpd.github.com/ \
@@ -85,7 +85,7 @@ PLIST_FILES+=	libexec/proftpd/${m}.a \
 .endfor
 PLIST_DIRSTRY+=	libexec/proftpd
 .else
-OPTIONS_DEFINE=	HTMLDOCS IPV6 NLS MEMCACHE PCRE
+OPTIONS_DEFINE=	DOCS HTMLDOCS IPV6 NLS MEMCACHE PCRE
 OPTIONS_DEFAULT=	IPV6 NLS PCRE
 
 HTMLDOCS_DESC=		Include HTML documentation
@@ -158,8 +158,7 @@ CONFIGURE_ARGS+=	--disable-ipv6
 
 .if ${PORT_OPTIONS:MNLS}
 CONFIGURE_ARGS+=	--enable-nls
-USES+=	gettext
-PROFTPD_LIBS+=	-lintl -L${LOCALBASE}/lib
+USES+=	gettext iconv
 PLIST_SUB+=	NLS=""
 .else
 PLIST_SUB+=	NLS="@comment "
@@ -198,12 +197,16 @@ CONFIGURE_ARGS+=	--with-shared=${_MODULE
 CONFIGURE_ARGS+=	--with-includes=${INCLUDEDIRS}
 CONFIGURE_ARGS+=	--with-libraries=${LIBDIRS}
 
+.include <bsd.port.pre.mk>
+
 .if !defined(_BUILDING_PROFTPD_MODULE)
 
-post-patch:
-.if ${PORT_OPTIONS:MNLS}
-	@${REINPLACE_CMD} -e 's|-lsupp|-lsupp -lintl|g' ${WRKSRC}/Makefile.in
+.if empty(ICONV_LIB)
+CONFIGURE_ARGS+=	ac_cv_lib_iconv_iconv_open=no \
+			ac_cv_lib_iconv_libiconv_open=no
 .endif
+
+post-patch:
 	@${REINPLACE_CMD} -e 's|proftpd\.conf|proftpd.conf.sample|g' ${WRKSRC}/Makefile.in
 
 pre-configure:
@@ -247,4 +250,4 @@ post-install:
 	@${INSTALL_MAN} ${WRKSRC}/src/ftpdctl.8 ${STAGEDIR}${MAN8PREFIX}/man/man8/
 .endif #!defined(_BUILDING_PROFTPD_MODULE)
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 3 Martin Matuska freebsd_committer freebsd_triage 2014-03-27 23:34:54 UTC
State Changed
From-To: open->closed

Committed. Thanks!