From nobody@FreeBSD.org  Sun Dec  8 16:17:23 2013
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1])
	(using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by hub.freebsd.org (Postfix) with ESMTPS id 269DB718
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Dec 2013 16:17:23 +0000 (UTC)
Received: from oldred.freebsd.org (oldred.freebsd.org [IPv6:2001:1900:2254:206a::50:4])
	(using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.freebsd.org (Postfix) with ESMTPS id 10BA21DE0
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  8 Dec 2013 16:17:23 +0000 (UTC)
Received: from oldred.freebsd.org ([127.0.1.6])
	by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id rB8GHMhJ033921
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 8 Dec 2013 16:17:22 GMT
	(envelope-from nobody@oldred.freebsd.org)
Received: (from nobody@localhost)
	by oldred.freebsd.org (8.14.5/8.14.5/Submit) id rB8GHMsA033914;
	Sun, 8 Dec 2013 16:17:22 GMT
	(envelope-from nobody)
Message-Id: <201312081617.rB8GHMsA033914@oldred.freebsd.org>
Date: Sun, 8 Dec 2013 16:17:22 GMT
From: Michael Gmelin <freebsd@grem.de>
To: freebsd-gnats-submit@FreeBSD.org
Subject: converters/php5-iconv: iconv transliteration support broken on 10
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         184596
>Category:       ports
>Synopsis:       converters/php5-iconv: iconv transliteration support broken on 10
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    ale
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Dec 08 16:20:00 UTC 2013
>Closed-Date:    Wed Jan 29 22:03:44 CET 2014
>Last-Modified:  Wed Jan 29 22:03:44 CET 2014
>Originator:     Michael Gmelin
>Release:        10.0-BETA3
>Organization:
Grem Equity GmbH
>Environment:
FreeBSD srv10 10.0-BETA3 FreeBSD 10.0-BETA3 #0: Mon Dec 2 20:44:29 UTC 2013 root@:/usr/obj/usr/src/sys/GENERIC amd64
>Description:
php5-iconv has been changed to use FreeBSD's native iconv implementation where available (read FreeBSD 10). Unfortunately FreeBSD doesn't support GNU iconv's TRANSLIT and IGNORE extensions, which are clearly documented to be supported unconditionally on any platform by the PHP project:

http://www.php.net/manual/en/function.iconv.php
"out_charset 

 The output charset. 

If you append the string //TRANSLIT to out_charset transliteration is activated. This means that when a character can't be represented in the target charset, it can be approximated through one or several similarly looking characters. If you append the string //IGNORE, characters that cannot be represented in the target charset are silently discarded. Otherwise, str is cut from the first illegal character and an E_NOTICE is generated."

As a result, PHP code that runs correctly on other operating systems or FreeBSD < 10 will break in subtle ways on 10.
>How-To-Repeat:
Run the following code snippet:

cat t.php <<EOF
<?php

print iconv("UTF-8", "ISO-8859-1//TRANSLIT", "T\xc5\xbdst\n");

?>
EOF

FreeBSD 9.2:
$ php t.php
TZst

FreeBSD 10 BETA3:
$ php t.php
T?st
>Fix:
Implement TRANSLIT/IGNORE extensions in base or make the port use converters/libiconv.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->ale 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Sun Dec 8 16:20:08 UTC 2013 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=184596 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/184596: commit references a PR
Date: Wed, 29 Jan 2014 20:41:36 +0000 (UTC)

 Author: tijl
 Date: Wed Jan 29 20:41:27 2014
 New Revision: 341778
 URL: http://svnweb.freebsd.org/changeset/ports/341778
 QAT: https://qat.redports.org/buildarchive/r341778/
 
 Log:
   Allow the use of //TRANSLIT and //IGNORE with PHP iconv.
   
   PR:		ports/184596
   Tested by:	grembo
   Approved by:	ale (maintainer)
 
 Modified:
   head/converters/php5-iconv/Makefile
   head/converters/php53-iconv/Makefile
   head/converters/php55-iconv/Makefile
   head/lang/php5/Makefile.ext
   head/lang/php53/Makefile.ext
   head/lang/php55/Makefile.ext
 
 Modified: head/converters/php5-iconv/Makefile
 ==============================================================================
 --- head/converters/php5-iconv/Makefile	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/converters/php5-iconv/Makefile	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -1,6 +1,7 @@
  # Created by: Alex Dupre <ale@FreeBSD.org>
  # $FreeBSD$
  
 +PORTREVISION=	1
  CATEGORIES=	converters
  
  MASTERDIR=	${.CURDIR}/../../lang/php5
 
 Modified: head/converters/php53-iconv/Makefile
 ==============================================================================
 --- head/converters/php53-iconv/Makefile	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/converters/php53-iconv/Makefile	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -1,5 +1,6 @@
  # $FreeBSD$
  
 +PORTREVISION=	1
  CATEGORIES=	converters
  
  MASTERDIR=	${.CURDIR}/../../lang/php53
 
 Modified: head/converters/php55-iconv/Makefile
 ==============================================================================
 --- head/converters/php55-iconv/Makefile	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/converters/php55-iconv/Makefile	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -1,6 +1,7 @@
  # Created by: Alex Dupre <ale@FreeBSD.org>
  # $FreeBSD$
  
 +PORTREVISION=	1
  CATEGORIES=	converters
  
  MASTERDIR=	${.CURDIR}/../../lang/php55
 
 Modified: head/lang/php5/Makefile.ext
 ==============================================================================
 --- head/lang/php5/Makefile.ext	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/lang/php5/Makefile.ext	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -128,7 +128,7 @@ CONFIGURE_ARGS+=--enable-hash \
  .if ${PHP_MODNAME} == "iconv"
  CONFIGURE_ARGS+=--with-iconv
  
 -USES+=	iconv
 +USES+=	iconv:translit
  .endif
  
  .if ${PHP_MODNAME} == "imap"
 
 Modified: head/lang/php53/Makefile.ext
 ==============================================================================
 --- head/lang/php53/Makefile.ext	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/lang/php53/Makefile.ext	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -127,7 +127,7 @@ CONFIGURE_ARGS+=--enable-hash \
  .if ${PHP_MODNAME} == "iconv"
  CONFIGURE_ARGS+=--with-iconv
  
 -USES+=	iconv
 +USES+=	iconv:translit
  .endif
  
  .if ${PHP_MODNAME} == "imap"
 
 Modified: head/lang/php55/Makefile.ext
 ==============================================================================
 --- head/lang/php55/Makefile.ext	Wed Jan 29 20:39:35 2014	(r341777)
 +++ head/lang/php55/Makefile.ext	Wed Jan 29 20:41:27 2014	(r341778)
 @@ -128,7 +128,7 @@ CONFIGURE_ARGS+=--enable-hash \
  .if ${PHP_MODNAME} == "iconv"
  CONFIGURE_ARGS+=--with-iconv
  
 -USES+=	iconv
 +USES+=	iconv:translit
  .endif
  
  .if ${PHP_MODNAME} == "imap"
 _______________________________________________
 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"
 
State-Changed-From-To: open->closed 
State-Changed-By: tijl 
State-Changed-When: Wed Jan 29 22:03:04 CET 2014 
State-Changed-Why:  
Fixed in r341778. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=184596 
>Unformatted:
