[arch-commits] Commit in icu/repos (10 files)

Jan Steffens heftig at archlinux.org
Sat Nov 10 21:07:39 UTC 2012


    Date: Saturday, November 10, 2012 @ 16:07:38
  Author: heftig
Revision: 170742

archrelease: copy trunk to staging-i686, staging-x86_64

Added:
  icu/repos/staging-i686/PKGBUILD
    (from rev 170741, icu/trunk/PKGBUILD)
  icu/repos/staging-i686/changeset_32780.diff
    (from rev 170741, icu/trunk/changeset_32780.diff)
  icu/repos/staging-i686/icu.8198.revert.icu5431.patch
    (from rev 170741, icu/trunk/icu.8198.revert.icu5431.patch)
  icu/repos/staging-x86_64/PKGBUILD
    (from rev 170741, icu/trunk/PKGBUILD)
  icu/repos/staging-x86_64/changeset_32780.diff
    (from rev 170741, icu/trunk/changeset_32780.diff)
  icu/repos/staging-x86_64/icu.8198.revert.icu5431.patch
    (from rev 170741, icu/trunk/icu.8198.revert.icu5431.patch)
Deleted:
  icu/repos/staging-i686/PKGBUILD
  icu/repos/staging-i686/icu.8198.revert.icu5431.patch
  icu/repos/staging-x86_64/PKGBUILD
  icu/repos/staging-x86_64/icu.8198.revert.icu5431.patch

----------------------------------------------+
 staging-i686/PKGBUILD                        |   86 ++++----
 staging-i686/changeset_32780.diff            |   67 ++++++
 staging-i686/icu.8198.revert.icu5431.patch   |  258 ++++++++++++-------------
 staging-x86_64/PKGBUILD                      |   86 ++++----
 staging-x86_64/changeset_32780.diff          |   67 ++++++
 staging-x86_64/icu.8198.revert.icu5431.patch |  258 ++++++++++++-------------
 6 files changed, 484 insertions(+), 338 deletions(-)

Deleted: staging-i686/PKGBUILD
===================================================================
--- staging-i686/PKGBUILD	2012-11-10 21:05:57 UTC (rev 170741)
+++ staging-i686/PKGBUILD	2012-11-10 21:07:38 UTC (rev 170742)
@@ -1,40 +0,0 @@
-# $Id$
-# Maintainer: Andreas Radke <andyrtr at archlinux.org>
-# Contributor: Art Gramlich <art at gramlich-net.com>
-
-pkgname=icu
-pkgver=50.1
-pkgrel=1
-pkgdesc="International Components for Unicode library"
-arch=(i686 x86_64)
-url="http://www.icu-project.org/"
-license=('custom:"icu"')
-depends=('gcc-libs>=4.7.1-5' 'sh')
-source=(#http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver/./_}-src.tgz
-	    http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver//./_}-src.tgz
-	    icu.8198.revert.icu5431.patch)
-md5sums=('cf7bf9e56aa6c2057a8b6f464046483e'
-         'ebd5470fc969c75e52baf4af94a9ee82')
-
-build() {
-  cd ${srcdir}/icu/source
-  # fix Malayalam encoding https://bugzilla.redhat.com/show_bug.cgi?id=654200
-  patch -Rp3 -i ${srcdir}/icu.8198.revert.icu5431.patch
-  ./configure --prefix=/usr \
-	--sysconfdir=/etc \
-	--mandir=/usr/share/man
-  make
-}
-
-check() {
-  cd "$srcdir/icu/source"
-  make -k check # passes all
-}
-
-package() {
-  cd ${srcdir}/icu/source
-  make -j1 DESTDIR=${pkgdir} install
-
-  # Install license
-  install -Dm644 ${srcdir}/icu/license.html ${pkgdir}/usr/share/licenses/icu/license.html
-}

Copied: icu/repos/staging-i686/PKGBUILD (from rev 170741, icu/trunk/PKGBUILD)
===================================================================
--- staging-i686/PKGBUILD	                        (rev 0)
+++ staging-i686/PKGBUILD	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,46 @@
+# $Id$
+# Maintainer: Andreas Radke <andyrtr at archlinux.org>
+# Contributor: Art Gramlich <art at gramlich-net.com>
+
+pkgname=icu
+pkgver=50.1
+pkgrel=2
+pkgdesc="International Components for Unicode library"
+arch=(i686 x86_64)
+url="http://www.icu-project.org/"
+license=('custom:"icu"')
+depends=('gcc-libs>=4.7.1-5' 'sh')
+source=(#http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver/./_}-src.tgz
+	    http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver//./_}-src.tgz
+	    icu.8198.revert.icu5431.patch changeset_32780.diff)
+md5sums=('cf7bf9e56aa6c2057a8b6f464046483e'
+         'ebd5470fc969c75e52baf4af94a9ee82'
+         '58f4b655e40dddc8e316600019b491b2')
+
+build() {
+  cd ${srcdir}/icu/source
+
+  # fix Malayalam encoding https://bugzilla.redhat.com/show_bug.cgi?id=654200
+  patch -Rp3 -i ${srcdir}/icu.8198.revert.icu5431.patch
+
+  # fix building clients without c++11 http://bugs.icu-project.org/trac/changeset/32780
+  patch -Np4 -i ${srcdir}/changeset_32780.diff
+
+  ./configure --prefix=/usr \
+	--sysconfdir=/etc \
+	--mandir=/usr/share/man
+  make
+}
+
+check() {
+  cd "$srcdir/icu/source"
+  make -k check # passes all
+}
+
+package() {
+  cd ${srcdir}/icu/source
+  make -j1 DESTDIR=${pkgdir} install
+
+  # Install license
+  install -Dm644 ${srcdir}/icu/license.html ${pkgdir}/usr/share/licenses/icu/license.html
+}

Copied: icu/repos/staging-i686/changeset_32780.diff (from rev 170741, icu/trunk/changeset_32780.diff)
===================================================================
--- staging-i686/changeset_32780.diff	                        (rev 0)
+++ staging-i686/changeset_32780.diff	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,67 @@
+Index: /icu/trunk/source/test/intltest/strtest.cpp
+===================================================================
+--- /icu/trunk/source/test/intltest/strtest.cpp	(revision 32779)
++++ /icu/trunk/source/test/intltest/strtest.cpp	(revision 32780)
+@@ -1,5 +1,5 @@
+ /********************************************************************
+  * COPYRIGHT: 
+- * Copyright (c) 1997-2011, International Business Machines Corporation and
++ * Copyright (c) 1997-2012, International Business Machines Corporation and
+  * others. All Rights Reserved.
+  ********************************************************************/
+@@ -95,5 +95,5 @@
+ StringTest::Test_U_STRING() {
+     U_STRING_INIT(ustringVar, "aZ0 -", 5);
+-    if( sizeof(ustringVar)/sizeof(*ustringVar)!=6 ||
++    if( u_strlen(ustringVar)!=5 ||
+         ustringVar[0]!=0x61 ||
+         ustringVar[1]!=0x5a ||
+Index: /icu/trunk/source/common/unicode/ustring.h
+===================================================================
+--- /icu/trunk/source/common/unicode/ustring.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/ustring.h	(revision 32780)
+@@ -940,5 +940,5 @@
+  */
+ #if defined(U_DECLARE_UTF16)
+-#   define U_STRING_DECL(var, cs, length) static const UChar var[(length)+1]=U_DECLARE_UTF16(cs)
++#   define U_STRING_DECL(var, cs, length) static const UChar *var=(const UChar *)U_DECLARE_UTF16(cs)
+     /**@stable ICU 2.0 */
+ #   define U_STRING_INIT(var, cs, length)
+Index: /icu/trunk/source/common/unicode/platform.h
+===================================================================
+--- /icu/trunk/source/common/unicode/platform.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/platform.h	(revision 32780)
+@@ -665,7 +665,7 @@
+      * gcc 4.4 defines the __CHAR16_TYPE__ macro to a usable type but
+      * does not support u"abc" string literals.
+-     * C++11 requires support for UTF-16 literals
++     * C++11 and C11 require support for UTF-16 literals
+      */
+-#   if (defined(__cplusplus) && __cplusplus >= 201103L)
++#   if (defined(__cplusplus) && __cplusplus >= 201103L) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L)
+ #       define U_HAVE_CHAR16_T 1
+ #   else
+Index: /icu/trunk/source/common/unicode/umachine.h
+===================================================================
+--- /icu/trunk/source/common/unicode/umachine.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/umachine.h	(revision 32780)
+@@ -257,5 +257,5 @@
+ /**
+  * \var UChar
+- * Define UChar to be char16_t, if available,
++ * Define UChar to be UCHAR_TYPE, if that is #defined (for example, to char16_t),
+  * or wchar_t if that is 16 bits wide; always assumed to be unsigned.
+  * If neither is available, then define UChar to be uint16_t.
+@@ -267,8 +267,8 @@
+  * @stable ICU 4.4
+  */
+-
+-/* Define UChar to be compatible with char16_t or wchar_t if possible. */
+-#if U_HAVE_CHAR16_T
+-    typedef char16_t UChar;
++#if defined(UCHAR_TYPE)
++    typedef UCHAR_TYPE UChar;
++/* Not #elif U_HAVE_CHAR16_T -- because that is type-incompatible with pre-C++11 callers
++    typedef char16_t UChar;  */
+ #elif U_SIZEOF_WCHAR_T==2
+     typedef wchar_t UChar;

Deleted: staging-i686/icu.8198.revert.icu5431.patch
===================================================================
--- staging-i686/icu.8198.revert.icu5431.patch	2012-11-10 21:05:57 UTC (rev 170741)
+++ staging-i686/icu.8198.revert.icu5431.patch	2012-11-10 21:07:38 UTC (rev 170742)
@@ -1,129 +0,0 @@
-Index: icu/trunk/source/layout/IndicReordering.cpp
-===================================================================
---- icu/trunk/source/layout/IndicReordering.cpp	(revision 25772)
-+++ icu/trunk/source/layout/IndicReordering.cpp	(revision 26090)
-@@ -126,4 +126,8 @@
-     FeatureMask fSMFeatures;
- 
-+    LEUnicode   fPreBaseConsonant;
-+    LEUnicode   fPreBaseVirama;
-+    le_int32    fPBCIndex;
-+    FeatureMask fPBCFeatures;
- 
-     void saveMatra(LEUnicode matra, le_int32 matraIndex, IndicClassTable::CharClass matraClass)
-@@ -172,5 +176,6 @@
-           fMatraFeatures(0), fMPreOutIndex(-1), fMPreFixups(mpreFixups),
-           fVMabove(0), fVMpost(0), fVMIndex(0), fVMFeatures(0),
--          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0)
-+          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0),
-+          fPreBaseConsonant(0), fPreBaseVirama(0), fPBCIndex(0), fPBCFeatures(0)
-     {
-         // nothing else to do...
-@@ -191,4 +196,6 @@
-         fVMabove = fVMpost  = 0;
-         fSMabove = fSMbelow = 0;
-+
-+        fPreBaseConsonant = fPreBaseVirama = 0;
-     }
- 
-@@ -386,4 +393,12 @@
-     }
- 
-+    void notePreBaseConsonant(le_uint32 index,LEUnicode PBConsonant, LEUnicode PBVirama, FeatureMask features)
-+    {
-+        fPBCIndex = index;
-+        fPreBaseConsonant = PBConsonant;
-+        fPreBaseVirama = PBVirama;
-+        fPBCFeatures = features;
-+    }
-+
-     void noteBaseConsonant()
-     {
-@@ -465,4 +480,20 @@
-     }
-     
-+    void writePreBaseConsonant()
-+    {
-+        // The TDIL spec says that consonant + virama + RRA should produce a rakar in Malayalam.  However,
-+        // it seems that almost none of the fonts for Malayalam are set up to handle this.
-+        // So, we're going to force the issue here by using the rakar as defined with RA in most fonts.
-+
-+        if (fPreBaseConsonant == 0x0d31) { // RRA
-+            fPreBaseConsonant = 0x0d30; // RA
-+        }
-+        
-+        if (fPreBaseConsonant != 0) {
-+            writeChar(fPreBaseConsonant, fPBCIndex, fPBCFeatures);
-+            writeChar(fPreBaseVirama,fPBCIndex-1,fPBCFeatures);
-+        }
-+    }
-+
-     le_int32 getOutputIndex()
-     {
-@@ -723,4 +754,5 @@
-             }
- 
-+            
-             IndicClassTable::CharClass charClass = CC_RESERVED;
-             IndicClassTable::CharClass nextClass = CC_RESERVED;
-@@ -730,7 +762,9 @@
-             le_bool  seenVattu = FALSE;
-             le_bool  seenBelowBaseForm = FALSE;
-+            le_bool  seenPreBaseForm = FALSE;
-             le_bool  hasNukta = FALSE;
-             le_bool  hasBelowBaseForm = FALSE;
-             le_bool  hasPostBaseForm = FALSE;
-+            le_bool  hasPreBaseForm = FALSE;
- 
-             if (postBase < markStart && classTable->isNukta(chars[postBase])) {
-@@ -746,12 +780,20 @@
-                 hasBelowBaseForm = IndicClassTable::hasBelowBaseForm(charClass) && !hasNukta;
-                 hasPostBaseForm  = IndicClassTable::hasPostBaseForm(charClass)  && !hasNukta;
-+                hasPreBaseForm = IndicClassTable::hasPreBaseForm(charClass) && !hasNukta;
- 
-                 if (IndicClassTable::isConsonant(charClass)) {
-                     if (postBaseLimit == 0 || seenVattu ||
-                         (baseConsonant > baseLimit && !classTable->isVirama(chars[baseConsonant - 1])) ||
--                        !(hasBelowBaseForm || hasPostBaseForm)) {
-+                        !(hasBelowBaseForm || hasPostBaseForm || hasPreBaseForm)) {
-                         break;
-                     }
- 
-+                    // Note any pre-base consonants
-+                    if ( baseConsonant == lastConsonant && lastConsonant > 0 && 
-+                         hasPreBaseForm && classTable->isVirama(chars[baseConsonant - 1])) {
-+                        output.notePreBaseConsonant(lastConsonant,chars[lastConsonant],chars[lastConsonant-1],tagArray2);
-+                        seenPreBaseForm = TRUE;
-+   
-+                    }
-                     // consonants with nuktas are never vattus
-                     seenVattu = IndicClassTable::isVattu(charClass) && !hasNukta;
-@@ -786,10 +828,12 @@
- 
-             // write any pre-base consonants
-+            output.writePreBaseConsonant();
-+
-             le_bool supressVattu = TRUE;
- 
-             for (i = baseLimit; i < baseConsonant; i += 1) {
-                 LEUnicode ch = chars[i];
--                // Don't put 'blwf' on first consonant.
--                FeatureMask features = (i == baseLimit? tagArray2 : tagArray1);
-+                // Don't put 'pstf' or 'blwf' on anything before the base consonant.
-+                FeatureMask features = tagArray1 & ~( pstfFeatureMask | blwfFeatureMask );
- 
-                 charClass = classTable->getCharClass(ch);
-@@ -842,5 +886,5 @@
- 
-             // write below-base consonants
--            if (baseConsonant != lastConsonant) {
-+            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
-                 for (i = bcSpan + 1; i < postBase; i += 1) {
-                     output.writeChar(chars[i], i, tagArray1);
-@@ -872,5 +916,5 @@
-             // write post-base consonants
-             // FIXME: does this put the right tags on post-base consonants?
--            if (baseConsonant != lastConsonant) {
-+            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
-                 if (postBase <= lastConsonant) {
-                     for (i = postBase; i <= lastConsonant; i += 1) {

Copied: icu/repos/staging-i686/icu.8198.revert.icu5431.patch (from rev 170741, icu/trunk/icu.8198.revert.icu5431.patch)
===================================================================
--- staging-i686/icu.8198.revert.icu5431.patch	                        (rev 0)
+++ staging-i686/icu.8198.revert.icu5431.patch	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,129 @@
+Index: icu/trunk/source/layout/IndicReordering.cpp
+===================================================================
+--- icu/trunk/source/layout/IndicReordering.cpp	(revision 25772)
++++ icu/trunk/source/layout/IndicReordering.cpp	(revision 26090)
+@@ -126,4 +126,8 @@
+     FeatureMask fSMFeatures;
+ 
++    LEUnicode   fPreBaseConsonant;
++    LEUnicode   fPreBaseVirama;
++    le_int32    fPBCIndex;
++    FeatureMask fPBCFeatures;
+ 
+     void saveMatra(LEUnicode matra, le_int32 matraIndex, IndicClassTable::CharClass matraClass)
+@@ -172,5 +176,6 @@
+           fMatraFeatures(0), fMPreOutIndex(-1), fMPreFixups(mpreFixups),
+           fVMabove(0), fVMpost(0), fVMIndex(0), fVMFeatures(0),
+-          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0)
++          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0),
++          fPreBaseConsonant(0), fPreBaseVirama(0), fPBCIndex(0), fPBCFeatures(0)
+     {
+         // nothing else to do...
+@@ -191,4 +196,6 @@
+         fVMabove = fVMpost  = 0;
+         fSMabove = fSMbelow = 0;
++
++        fPreBaseConsonant = fPreBaseVirama = 0;
+     }
+ 
+@@ -386,4 +393,12 @@
+     }
+ 
++    void notePreBaseConsonant(le_uint32 index,LEUnicode PBConsonant, LEUnicode PBVirama, FeatureMask features)
++    {
++        fPBCIndex = index;
++        fPreBaseConsonant = PBConsonant;
++        fPreBaseVirama = PBVirama;
++        fPBCFeatures = features;
++    }
++
+     void noteBaseConsonant()
+     {
+@@ -465,4 +480,20 @@
+     }
+     
++    void writePreBaseConsonant()
++    {
++        // The TDIL spec says that consonant + virama + RRA should produce a rakar in Malayalam.  However,
++        // it seems that almost none of the fonts for Malayalam are set up to handle this.
++        // So, we're going to force the issue here by using the rakar as defined with RA in most fonts.
++
++        if (fPreBaseConsonant == 0x0d31) { // RRA
++            fPreBaseConsonant = 0x0d30; // RA
++        }
++        
++        if (fPreBaseConsonant != 0) {
++            writeChar(fPreBaseConsonant, fPBCIndex, fPBCFeatures);
++            writeChar(fPreBaseVirama,fPBCIndex-1,fPBCFeatures);
++        }
++    }
++
+     le_int32 getOutputIndex()
+     {
+@@ -723,4 +754,5 @@
+             }
+ 
++            
+             IndicClassTable::CharClass charClass = CC_RESERVED;
+             IndicClassTable::CharClass nextClass = CC_RESERVED;
+@@ -730,7 +762,9 @@
+             le_bool  seenVattu = FALSE;
+             le_bool  seenBelowBaseForm = FALSE;
++            le_bool  seenPreBaseForm = FALSE;
+             le_bool  hasNukta = FALSE;
+             le_bool  hasBelowBaseForm = FALSE;
+             le_bool  hasPostBaseForm = FALSE;
++            le_bool  hasPreBaseForm = FALSE;
+ 
+             if (postBase < markStart && classTable->isNukta(chars[postBase])) {
+@@ -746,12 +780,20 @@
+                 hasBelowBaseForm = IndicClassTable::hasBelowBaseForm(charClass) && !hasNukta;
+                 hasPostBaseForm  = IndicClassTable::hasPostBaseForm(charClass)  && !hasNukta;
++                hasPreBaseForm = IndicClassTable::hasPreBaseForm(charClass) && !hasNukta;
+ 
+                 if (IndicClassTable::isConsonant(charClass)) {
+                     if (postBaseLimit == 0 || seenVattu ||
+                         (baseConsonant > baseLimit && !classTable->isVirama(chars[baseConsonant - 1])) ||
+-                        !(hasBelowBaseForm || hasPostBaseForm)) {
++                        !(hasBelowBaseForm || hasPostBaseForm || hasPreBaseForm)) {
+                         break;
+                     }
+ 
++                    // Note any pre-base consonants
++                    if ( baseConsonant == lastConsonant && lastConsonant > 0 && 
++                         hasPreBaseForm && classTable->isVirama(chars[baseConsonant - 1])) {
++                        output.notePreBaseConsonant(lastConsonant,chars[lastConsonant],chars[lastConsonant-1],tagArray2);
++                        seenPreBaseForm = TRUE;
++   
++                    }
+                     // consonants with nuktas are never vattus
+                     seenVattu = IndicClassTable::isVattu(charClass) && !hasNukta;
+@@ -786,10 +828,12 @@
+ 
+             // write any pre-base consonants
++            output.writePreBaseConsonant();
++
+             le_bool supressVattu = TRUE;
+ 
+             for (i = baseLimit; i < baseConsonant; i += 1) {
+                 LEUnicode ch = chars[i];
+-                // Don't put 'blwf' on first consonant.
+-                FeatureMask features = (i == baseLimit? tagArray2 : tagArray1);
++                // Don't put 'pstf' or 'blwf' on anything before the base consonant.
++                FeatureMask features = tagArray1 & ~( pstfFeatureMask | blwfFeatureMask );
+ 
+                 charClass = classTable->getCharClass(ch);
+@@ -842,5 +886,5 @@
+ 
+             // write below-base consonants
+-            if (baseConsonant != lastConsonant) {
++            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
+                 for (i = bcSpan + 1; i < postBase; i += 1) {
+                     output.writeChar(chars[i], i, tagArray1);
+@@ -872,5 +916,5 @@
+             // write post-base consonants
+             // FIXME: does this put the right tags on post-base consonants?
+-            if (baseConsonant != lastConsonant) {
++            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
+                 if (postBase <= lastConsonant) {
+                     for (i = postBase; i <= lastConsonant; i += 1) {

Deleted: staging-x86_64/PKGBUILD
===================================================================
--- staging-x86_64/PKGBUILD	2012-11-10 21:05:57 UTC (rev 170741)
+++ staging-x86_64/PKGBUILD	2012-11-10 21:07:38 UTC (rev 170742)
@@ -1,40 +0,0 @@
-# $Id$
-# Maintainer: Andreas Radke <andyrtr at archlinux.org>
-# Contributor: Art Gramlich <art at gramlich-net.com>
-
-pkgname=icu
-pkgver=50.1
-pkgrel=1
-pkgdesc="International Components for Unicode library"
-arch=(i686 x86_64)
-url="http://www.icu-project.org/"
-license=('custom:"icu"')
-depends=('gcc-libs>=4.7.1-5' 'sh')
-source=(#http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver/./_}-src.tgz
-	    http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver//./_}-src.tgz
-	    icu.8198.revert.icu5431.patch)
-md5sums=('cf7bf9e56aa6c2057a8b6f464046483e'
-         'ebd5470fc969c75e52baf4af94a9ee82')
-
-build() {
-  cd ${srcdir}/icu/source
-  # fix Malayalam encoding https://bugzilla.redhat.com/show_bug.cgi?id=654200
-  patch -Rp3 -i ${srcdir}/icu.8198.revert.icu5431.patch
-  ./configure --prefix=/usr \
-	--sysconfdir=/etc \
-	--mandir=/usr/share/man
-  make
-}
-
-check() {
-  cd "$srcdir/icu/source"
-  make -k check # passes all
-}
-
-package() {
-  cd ${srcdir}/icu/source
-  make -j1 DESTDIR=${pkgdir} install
-
-  # Install license
-  install -Dm644 ${srcdir}/icu/license.html ${pkgdir}/usr/share/licenses/icu/license.html
-}

Copied: icu/repos/staging-x86_64/PKGBUILD (from rev 170741, icu/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,46 @@
+# $Id$
+# Maintainer: Andreas Radke <andyrtr at archlinux.org>
+# Contributor: Art Gramlich <art at gramlich-net.com>
+
+pkgname=icu
+pkgver=50.1
+pkgrel=2
+pkgdesc="International Components for Unicode library"
+arch=(i686 x86_64)
+url="http://www.icu-project.org/"
+license=('custom:"icu"')
+depends=('gcc-libs>=4.7.1-5' 'sh')
+source=(#http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver/./_}-src.tgz
+	    http://download.icu-project.org/files/${pkgname}4c/${pkgver}/${pkgname}4c-${pkgver//./_}-src.tgz
+	    icu.8198.revert.icu5431.patch changeset_32780.diff)
+md5sums=('cf7bf9e56aa6c2057a8b6f464046483e'
+         'ebd5470fc969c75e52baf4af94a9ee82'
+         '58f4b655e40dddc8e316600019b491b2')
+
+build() {
+  cd ${srcdir}/icu/source
+
+  # fix Malayalam encoding https://bugzilla.redhat.com/show_bug.cgi?id=654200
+  patch -Rp3 -i ${srcdir}/icu.8198.revert.icu5431.patch
+
+  # fix building clients without c++11 http://bugs.icu-project.org/trac/changeset/32780
+  patch -Np4 -i ${srcdir}/changeset_32780.diff
+
+  ./configure --prefix=/usr \
+	--sysconfdir=/etc \
+	--mandir=/usr/share/man
+  make
+}
+
+check() {
+  cd "$srcdir/icu/source"
+  make -k check # passes all
+}
+
+package() {
+  cd ${srcdir}/icu/source
+  make -j1 DESTDIR=${pkgdir} install
+
+  # Install license
+  install -Dm644 ${srcdir}/icu/license.html ${pkgdir}/usr/share/licenses/icu/license.html
+}

Copied: icu/repos/staging-x86_64/changeset_32780.diff (from rev 170741, icu/trunk/changeset_32780.diff)
===================================================================
--- staging-x86_64/changeset_32780.diff	                        (rev 0)
+++ staging-x86_64/changeset_32780.diff	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,67 @@
+Index: /icu/trunk/source/test/intltest/strtest.cpp
+===================================================================
+--- /icu/trunk/source/test/intltest/strtest.cpp	(revision 32779)
++++ /icu/trunk/source/test/intltest/strtest.cpp	(revision 32780)
+@@ -1,5 +1,5 @@
+ /********************************************************************
+  * COPYRIGHT: 
+- * Copyright (c) 1997-2011, International Business Machines Corporation and
++ * Copyright (c) 1997-2012, International Business Machines Corporation and
+  * others. All Rights Reserved.
+  ********************************************************************/
+@@ -95,5 +95,5 @@
+ StringTest::Test_U_STRING() {
+     U_STRING_INIT(ustringVar, "aZ0 -", 5);
+-    if( sizeof(ustringVar)/sizeof(*ustringVar)!=6 ||
++    if( u_strlen(ustringVar)!=5 ||
+         ustringVar[0]!=0x61 ||
+         ustringVar[1]!=0x5a ||
+Index: /icu/trunk/source/common/unicode/ustring.h
+===================================================================
+--- /icu/trunk/source/common/unicode/ustring.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/ustring.h	(revision 32780)
+@@ -940,5 +940,5 @@
+  */
+ #if defined(U_DECLARE_UTF16)
+-#   define U_STRING_DECL(var, cs, length) static const UChar var[(length)+1]=U_DECLARE_UTF16(cs)
++#   define U_STRING_DECL(var, cs, length) static const UChar *var=(const UChar *)U_DECLARE_UTF16(cs)
+     /**@stable ICU 2.0 */
+ #   define U_STRING_INIT(var, cs, length)
+Index: /icu/trunk/source/common/unicode/platform.h
+===================================================================
+--- /icu/trunk/source/common/unicode/platform.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/platform.h	(revision 32780)
+@@ -665,7 +665,7 @@
+      * gcc 4.4 defines the __CHAR16_TYPE__ macro to a usable type but
+      * does not support u"abc" string literals.
+-     * C++11 requires support for UTF-16 literals
++     * C++11 and C11 require support for UTF-16 literals
+      */
+-#   if (defined(__cplusplus) && __cplusplus >= 201103L)
++#   if (defined(__cplusplus) && __cplusplus >= 201103L) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L)
+ #       define U_HAVE_CHAR16_T 1
+ #   else
+Index: /icu/trunk/source/common/unicode/umachine.h
+===================================================================
+--- /icu/trunk/source/common/unicode/umachine.h	(revision 32779)
++++ /icu/trunk/source/common/unicode/umachine.h	(revision 32780)
+@@ -257,5 +257,5 @@
+ /**
+  * \var UChar
+- * Define UChar to be char16_t, if available,
++ * Define UChar to be UCHAR_TYPE, if that is #defined (for example, to char16_t),
+  * or wchar_t if that is 16 bits wide; always assumed to be unsigned.
+  * If neither is available, then define UChar to be uint16_t.
+@@ -267,8 +267,8 @@
+  * @stable ICU 4.4
+  */
+-
+-/* Define UChar to be compatible with char16_t or wchar_t if possible. */
+-#if U_HAVE_CHAR16_T
+-    typedef char16_t UChar;
++#if defined(UCHAR_TYPE)
++    typedef UCHAR_TYPE UChar;
++/* Not #elif U_HAVE_CHAR16_T -- because that is type-incompatible with pre-C++11 callers
++    typedef char16_t UChar;  */
+ #elif U_SIZEOF_WCHAR_T==2
+     typedef wchar_t UChar;

Deleted: staging-x86_64/icu.8198.revert.icu5431.patch
===================================================================
--- staging-x86_64/icu.8198.revert.icu5431.patch	2012-11-10 21:05:57 UTC (rev 170741)
+++ staging-x86_64/icu.8198.revert.icu5431.patch	2012-11-10 21:07:38 UTC (rev 170742)
@@ -1,129 +0,0 @@
-Index: icu/trunk/source/layout/IndicReordering.cpp
-===================================================================
---- icu/trunk/source/layout/IndicReordering.cpp	(revision 25772)
-+++ icu/trunk/source/layout/IndicReordering.cpp	(revision 26090)
-@@ -126,4 +126,8 @@
-     FeatureMask fSMFeatures;
- 
-+    LEUnicode   fPreBaseConsonant;
-+    LEUnicode   fPreBaseVirama;
-+    le_int32    fPBCIndex;
-+    FeatureMask fPBCFeatures;
- 
-     void saveMatra(LEUnicode matra, le_int32 matraIndex, IndicClassTable::CharClass matraClass)
-@@ -172,5 +176,6 @@
-           fMatraFeatures(0), fMPreOutIndex(-1), fMPreFixups(mpreFixups),
-           fVMabove(0), fVMpost(0), fVMIndex(0), fVMFeatures(0),
--          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0)
-+          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0),
-+          fPreBaseConsonant(0), fPreBaseVirama(0), fPBCIndex(0), fPBCFeatures(0)
-     {
-         // nothing else to do...
-@@ -191,4 +196,6 @@
-         fVMabove = fVMpost  = 0;
-         fSMabove = fSMbelow = 0;
-+
-+        fPreBaseConsonant = fPreBaseVirama = 0;
-     }
- 
-@@ -386,4 +393,12 @@
-     }
- 
-+    void notePreBaseConsonant(le_uint32 index,LEUnicode PBConsonant, LEUnicode PBVirama, FeatureMask features)
-+    {
-+        fPBCIndex = index;
-+        fPreBaseConsonant = PBConsonant;
-+        fPreBaseVirama = PBVirama;
-+        fPBCFeatures = features;
-+    }
-+
-     void noteBaseConsonant()
-     {
-@@ -465,4 +480,20 @@
-     }
-     
-+    void writePreBaseConsonant()
-+    {
-+        // The TDIL spec says that consonant + virama + RRA should produce a rakar in Malayalam.  However,
-+        // it seems that almost none of the fonts for Malayalam are set up to handle this.
-+        // So, we're going to force the issue here by using the rakar as defined with RA in most fonts.
-+
-+        if (fPreBaseConsonant == 0x0d31) { // RRA
-+            fPreBaseConsonant = 0x0d30; // RA
-+        }
-+        
-+        if (fPreBaseConsonant != 0) {
-+            writeChar(fPreBaseConsonant, fPBCIndex, fPBCFeatures);
-+            writeChar(fPreBaseVirama,fPBCIndex-1,fPBCFeatures);
-+        }
-+    }
-+
-     le_int32 getOutputIndex()
-     {
-@@ -723,4 +754,5 @@
-             }
- 
-+            
-             IndicClassTable::CharClass charClass = CC_RESERVED;
-             IndicClassTable::CharClass nextClass = CC_RESERVED;
-@@ -730,7 +762,9 @@
-             le_bool  seenVattu = FALSE;
-             le_bool  seenBelowBaseForm = FALSE;
-+            le_bool  seenPreBaseForm = FALSE;
-             le_bool  hasNukta = FALSE;
-             le_bool  hasBelowBaseForm = FALSE;
-             le_bool  hasPostBaseForm = FALSE;
-+            le_bool  hasPreBaseForm = FALSE;
- 
-             if (postBase < markStart && classTable->isNukta(chars[postBase])) {
-@@ -746,12 +780,20 @@
-                 hasBelowBaseForm = IndicClassTable::hasBelowBaseForm(charClass) && !hasNukta;
-                 hasPostBaseForm  = IndicClassTable::hasPostBaseForm(charClass)  && !hasNukta;
-+                hasPreBaseForm = IndicClassTable::hasPreBaseForm(charClass) && !hasNukta;
- 
-                 if (IndicClassTable::isConsonant(charClass)) {
-                     if (postBaseLimit == 0 || seenVattu ||
-                         (baseConsonant > baseLimit && !classTable->isVirama(chars[baseConsonant - 1])) ||
--                        !(hasBelowBaseForm || hasPostBaseForm)) {
-+                        !(hasBelowBaseForm || hasPostBaseForm || hasPreBaseForm)) {
-                         break;
-                     }
- 
-+                    // Note any pre-base consonants
-+                    if ( baseConsonant == lastConsonant && lastConsonant > 0 && 
-+                         hasPreBaseForm && classTable->isVirama(chars[baseConsonant - 1])) {
-+                        output.notePreBaseConsonant(lastConsonant,chars[lastConsonant],chars[lastConsonant-1],tagArray2);
-+                        seenPreBaseForm = TRUE;
-+   
-+                    }
-                     // consonants with nuktas are never vattus
-                     seenVattu = IndicClassTable::isVattu(charClass) && !hasNukta;
-@@ -786,10 +828,12 @@
- 
-             // write any pre-base consonants
-+            output.writePreBaseConsonant();
-+
-             le_bool supressVattu = TRUE;
- 
-             for (i = baseLimit; i < baseConsonant; i += 1) {
-                 LEUnicode ch = chars[i];
--                // Don't put 'blwf' on first consonant.
--                FeatureMask features = (i == baseLimit? tagArray2 : tagArray1);
-+                // Don't put 'pstf' or 'blwf' on anything before the base consonant.
-+                FeatureMask features = tagArray1 & ~( pstfFeatureMask | blwfFeatureMask );
- 
-                 charClass = classTable->getCharClass(ch);
-@@ -842,5 +886,5 @@
- 
-             // write below-base consonants
--            if (baseConsonant != lastConsonant) {
-+            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
-                 for (i = bcSpan + 1; i < postBase; i += 1) {
-                     output.writeChar(chars[i], i, tagArray1);
-@@ -872,5 +916,5 @@
-             // write post-base consonants
-             // FIXME: does this put the right tags on post-base consonants?
--            if (baseConsonant != lastConsonant) {
-+            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
-                 if (postBase <= lastConsonant) {
-                     for (i = postBase; i <= lastConsonant; i += 1) {

Copied: icu/repos/staging-x86_64/icu.8198.revert.icu5431.patch (from rev 170741, icu/trunk/icu.8198.revert.icu5431.patch)
===================================================================
--- staging-x86_64/icu.8198.revert.icu5431.patch	                        (rev 0)
+++ staging-x86_64/icu.8198.revert.icu5431.patch	2012-11-10 21:07:38 UTC (rev 170742)
@@ -0,0 +1,129 @@
+Index: icu/trunk/source/layout/IndicReordering.cpp
+===================================================================
+--- icu/trunk/source/layout/IndicReordering.cpp	(revision 25772)
++++ icu/trunk/source/layout/IndicReordering.cpp	(revision 26090)
+@@ -126,4 +126,8 @@
+     FeatureMask fSMFeatures;
+ 
++    LEUnicode   fPreBaseConsonant;
++    LEUnicode   fPreBaseVirama;
++    le_int32    fPBCIndex;
++    FeatureMask fPBCFeatures;
+ 
+     void saveMatra(LEUnicode matra, le_int32 matraIndex, IndicClassTable::CharClass matraClass)
+@@ -172,5 +176,6 @@
+           fMatraFeatures(0), fMPreOutIndex(-1), fMPreFixups(mpreFixups),
+           fVMabove(0), fVMpost(0), fVMIndex(0), fVMFeatures(0),
+-          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0)
++          fSMabove(0), fSMbelow(0), fSMIndex(0), fSMFeatures(0),
++          fPreBaseConsonant(0), fPreBaseVirama(0), fPBCIndex(0), fPBCFeatures(0)
+     {
+         // nothing else to do...
+@@ -191,4 +196,6 @@
+         fVMabove = fVMpost  = 0;
+         fSMabove = fSMbelow = 0;
++
++        fPreBaseConsonant = fPreBaseVirama = 0;
+     }
+ 
+@@ -386,4 +393,12 @@
+     }
+ 
++    void notePreBaseConsonant(le_uint32 index,LEUnicode PBConsonant, LEUnicode PBVirama, FeatureMask features)
++    {
++        fPBCIndex = index;
++        fPreBaseConsonant = PBConsonant;
++        fPreBaseVirama = PBVirama;
++        fPBCFeatures = features;
++    }
++
+     void noteBaseConsonant()
+     {
+@@ -465,4 +480,20 @@
+     }
+     
++    void writePreBaseConsonant()
++    {
++        // The TDIL spec says that consonant + virama + RRA should produce a rakar in Malayalam.  However,
++        // it seems that almost none of the fonts for Malayalam are set up to handle this.
++        // So, we're going to force the issue here by using the rakar as defined with RA in most fonts.
++
++        if (fPreBaseConsonant == 0x0d31) { // RRA
++            fPreBaseConsonant = 0x0d30; // RA
++        }
++        
++        if (fPreBaseConsonant != 0) {
++            writeChar(fPreBaseConsonant, fPBCIndex, fPBCFeatures);
++            writeChar(fPreBaseVirama,fPBCIndex-1,fPBCFeatures);
++        }
++    }
++
+     le_int32 getOutputIndex()
+     {
+@@ -723,4 +754,5 @@
+             }
+ 
++            
+             IndicClassTable::CharClass charClass = CC_RESERVED;
+             IndicClassTable::CharClass nextClass = CC_RESERVED;
+@@ -730,7 +762,9 @@
+             le_bool  seenVattu = FALSE;
+             le_bool  seenBelowBaseForm = FALSE;
++            le_bool  seenPreBaseForm = FALSE;
+             le_bool  hasNukta = FALSE;
+             le_bool  hasBelowBaseForm = FALSE;
+             le_bool  hasPostBaseForm = FALSE;
++            le_bool  hasPreBaseForm = FALSE;
+ 
+             if (postBase < markStart && classTable->isNukta(chars[postBase])) {
+@@ -746,12 +780,20 @@
+                 hasBelowBaseForm = IndicClassTable::hasBelowBaseForm(charClass) && !hasNukta;
+                 hasPostBaseForm  = IndicClassTable::hasPostBaseForm(charClass)  && !hasNukta;
++                hasPreBaseForm = IndicClassTable::hasPreBaseForm(charClass) && !hasNukta;
+ 
+                 if (IndicClassTable::isConsonant(charClass)) {
+                     if (postBaseLimit == 0 || seenVattu ||
+                         (baseConsonant > baseLimit && !classTable->isVirama(chars[baseConsonant - 1])) ||
+-                        !(hasBelowBaseForm || hasPostBaseForm)) {
++                        !(hasBelowBaseForm || hasPostBaseForm || hasPreBaseForm)) {
+                         break;
+                     }
+ 
++                    // Note any pre-base consonants
++                    if ( baseConsonant == lastConsonant && lastConsonant > 0 && 
++                         hasPreBaseForm && classTable->isVirama(chars[baseConsonant - 1])) {
++                        output.notePreBaseConsonant(lastConsonant,chars[lastConsonant],chars[lastConsonant-1],tagArray2);
++                        seenPreBaseForm = TRUE;
++   
++                    }
+                     // consonants with nuktas are never vattus
+                     seenVattu = IndicClassTable::isVattu(charClass) && !hasNukta;
+@@ -786,10 +828,12 @@
+ 
+             // write any pre-base consonants
++            output.writePreBaseConsonant();
++
+             le_bool supressVattu = TRUE;
+ 
+             for (i = baseLimit; i < baseConsonant; i += 1) {
+                 LEUnicode ch = chars[i];
+-                // Don't put 'blwf' on first consonant.
+-                FeatureMask features = (i == baseLimit? tagArray2 : tagArray1);
++                // Don't put 'pstf' or 'blwf' on anything before the base consonant.
++                FeatureMask features = tagArray1 & ~( pstfFeatureMask | blwfFeatureMask );
+ 
+                 charClass = classTable->getCharClass(ch);
+@@ -842,5 +886,5 @@
+ 
+             // write below-base consonants
+-            if (baseConsonant != lastConsonant) {
++            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
+                 for (i = bcSpan + 1; i < postBase; i += 1) {
+                     output.writeChar(chars[i], i, tagArray1);
+@@ -872,5 +916,5 @@
+             // write post-base consonants
+             // FIXME: does this put the right tags on post-base consonants?
+-            if (baseConsonant != lastConsonant) {
++            if (baseConsonant != lastConsonant && !seenPreBaseForm) {
+                 if (postBase <= lastConsonant) {
+                     for (i = postBase; i <= lastConsonant; i += 1) {




More information about the arch-commits mailing list