$OpenBSD: patch-icu_icu-2_6_patch,v 1.3 2006/12/13 10:25:14 robert Exp $
--- icu/icu-2.6.patch.orig.port	Mon Dec 11 22:57:49 2006
+++ icu/icu-2.6.patch	Mon Dec 11 23:01:20 2006
@@ -1,21 +1,5 @@
-*** misc/icu/source/icudefs.mk.in	Tue Jun  3 08:44:40 2003
---- misc/build/icu/source/icudefs.mk.in	Thu Aug 31 13:24:31 2006
-***************
-*** 136,142 ****
---- 136,146 ----
-  SHLIB.cc=     $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared
-  
-  # Environment variable to set a runtime search path
-+ ifeq ($(OS), IRIX)
-+ LDLIBRARYPATH_ENVVAR = LD_LIBRARYN32_PATH
-+ else
-  LDLIBRARYPATH_ENVVAR = LD_LIBRARY_PATH
-+ endif
-  
-  # Versioned target for a shared library.
-  FINAL_SO_TARGET = $(SO_TARGET).$(SO_TARGET_VERSION)
 *** misc/icu/source/common/putil.c	Tue Jun  3 08:44:38 2003
---- misc/build/icu/source/common/putil.c	Thu Aug 31 13:27:44 2006
+--- misc/build/icu/source/common/putil.c	Mon Dec 11 22:58:07 2006
 ***************
 *** 35,40 ****
 --- 35,43 ----
@@ -55,7 +39,7 @@
   #ifndef __USE_POSIX
   #define __USE_POSIX
 *** misc/icu/source/common/unicode/rbbi.h	Tue Jun 10 20:04:02 2003
---- misc/build/icu/source/common/unicode/rbbi.h	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/common/unicode/rbbi.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 106,119 ****
       //=======================================================================
@@ -74,7 +58,7 @@
        *             are created via this constructor; the rules are compiled
 --- 106,111 ----
 ***************
-*** 128,137 ****
+*** 128,136 ****
       friend class RBBIRuleBuilder; /** @internal */
       friend class BreakIterator;
   
@@ -84,13 +68,12 @@
   
       /** Default constructor.  Creates an empty shell of an iterator, with no
        *  rules or text to iterate over.   Object can subsequently be assigned to.
-       *  @draft ICU 2.2
---- 120,135 ----
+--- 120,134 ----
       friend class RBBIRuleBuilder; /** @internal */
       friend class BreakIterator;
   
   public:
-  
++ 
 +     /**
 +      * This constructor uses the udata interface to create a BreakIterator
 +      * whose internal tables live in a memory-mapped file.  "image" is a pointer
@@ -98,12 +81,11 @@
 +      * @internal
 +      */
 +     RuleBasedBreakIterator(UDataMemory* image, UErrorCode &status);
-+ 
+  
       /** Default constructor.  Creates an empty shell of an iterator, with no
        *  rules or text to iterate over.   Object can subsequently be assigned to.
-       *  @draft ICU 2.2
 *** misc/icu/source/common/unicode/unistr.h	Fri Jun  6 21:06:42 2003
---- misc/build/icu/source/common/unicode/unistr.h	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/common/unicode/unistr.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 3183,3189 ****
   //========================================
@@ -206,11 +188,53 @@
     }
   }
   
+*** misc/icu/source/common/unicode/urename.h	Tue Jun 10 00:43:14 2003
+--- misc/build/icu/source/common/unicode/urename.h	Mon Dec 11 22:58:08 2006
+***************
+*** 25,31 ****
+     that do not use Autoconf. */
+  /* #define U_DISABLE_RENAMING 1 */
+  
+! #if !U_DISABLE_RENAMING
+  
+  /* C exports renaming data */
+  
+--- 25,31 ----
+     that do not use Autoconf. */
+  /* #define U_DISABLE_RENAMING 1 */
+  
+! #if !defined U_DISABLE_RENAMING || !U_DISABLE_RENAMING
+  
+  /* C exports renaming data */
+  
+*** misc/icu/source/common/unicode/utypes.h	Tue Jun 10 20:18:00 2003
+--- misc/build/icu/source/common/unicode/utypes.h	Mon Dec 11 22:58:08 2006
+***************
+*** 420,428 ****
+   *
+   * Note: This is currently only done on Windows because
+   * some Linux/Unix compilers have problems with defining global new/delete.
+!  * On Windows, WIN32 is defined, and it is _MSC_Ver>=1200 for MSVC 6.0 and higher.
+   */
+! #if defined(XP_CPLUSPLUS) && defined(WIN32) && (_MSC_Ver>=1200) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_USTDIO_IMPLEMENTATION))
+  
+  /**
+   * Global operator new, defined only inside ICU4C, must not be used.
+--- 420,428 ----
+   *
+   * Note: This is currently only done on Windows because
+   * some Linux/Unix compilers have problems with defining global new/delete.
+!  * On Windows, WIN32 is defined, and it is _MSC_VER>=1200 for MSVC 6.0 and higher.
+   */
+! #if defined(XP_CPLUSPLUS) && defined(WIN32) && (_MSC_VER>=1200) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_USTDIO_IMPLEMENTATION))
+  
+  /**
+   * Global operator new, defined only inside ICU4C, must not be used.
 *** misc/icu/source/config/mh-bsd-gcc	Thu May  2 01:48:10 2002
---- misc/build/icu/source/config/mh-bsd-gcc	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/config/mh-bsd-gcc	Mon Dec 11 22:58:07 2006
 ***************
-*** 10,15 ****
---- 10,18 ----
+*** 10,21 ****
+--- 10,30 ----
   GEN_DEPS.cc=	$(CXX) -E -MM $(DEFS) $(CPPFLAGS)
   
   ## Flags for position independent code
@@ -220,9 +244,6 @@
   SHAREDLIBCFLAGS = -fPIC
   SHAREDLIBCXXFLAGS = -fPIC
   SHAREDLIBCPPFLAGS = -DPIC
-***************
-*** 16,21 ****
---- 19,30 ----
   
   ## Compiler switch to embed a runtime search path
   LD_RPATH=	
@@ -236,7 +257,7 @@
   
   ## Compiler switch to embed a library name
 *** misc/icu/source/config/mh-darwin	Tue Jun  3 22:52:56 2003
---- misc/build/icu/source/config/mh-darwin	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/config/mh-darwin	Mon Dec 11 22:58:07 2006
 ***************
 *** 15,30 ****
   LD_FLAGS += -headerpad_max_install_names
@@ -313,7 +334,7 @@
   
   ## End Darwin-specific setup
 *** misc/icu/source/config/mh-irix	Thu Jan 10 03:41:40 2002
---- misc/build/icu/source/config/mh-irix	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/config/mh-irix	Mon Dec 11 22:58:07 2006
 ***************
 *** 10,15 ****
 --- 10,19 ----
@@ -328,7 +349,7 @@
   GEN_DEPS.c=	$(CC) -E -M $(DEFS) $(CPPFLAGS)
   GEN_DEPS.cc=	$(CXX) -E -M $(DEFS) $(CPPFLAGS)
 *** misc/icu/source/config/mh-linux	Thu Jan 24 18:35:04 2002
---- misc/build/icu/source/config/mh-linux	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/config/mh-linux	Mon Dec 11 22:58:07 2006
 ***************
 *** 10,15 ****
 --- 10,18 ----
@@ -342,25 +363,25 @@
   SHAREDLIBCXXFLAGS = -fPIC
   SHAREDLIBCPPFLAGS = -DPIC
 ***************
-*** 22,27 ****
---- 25,37 ----
+*** 21,26 ****
+--- 24,36 ----
+  ## Compiler switch to embed a runtime search path
   LD_RPATH=	
   LD_RPATH_PRE = -Wl,-rpath,
-  
++ 
 + ## Force RPATH=$ORIGIN to locate own dependencies w/o need for LD_LIBRARY_PATH
 + ENABLE_RPATH=YES
 + RPATHLDFLAGS=${LD_RPATH_PRE}'$$ORIGIN'
 + 
 + #SH#	ENABLE_RPATH=YES
 + #SH#	RPATHLDFLAGS="${LD_RPATH_PRE}'$$ORIGIN'"
-+ 
+  
   ## Compiler switch to embed a library name
   LD_SONAME = -Wl,-soname -Wl,$(MIDDLE_SO_TARGET)
-  
 *** misc/icu/source/config/mh-solaris	Tue Jul 30 04:46:10 2002
---- misc/build/icu/source/config/mh-solaris	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/config/mh-solaris	Mon Dec 11 22:58:07 2006
 ***************
-*** 23,39 ****
+*** 23,38 ****
   
   ## Commands to link
   ## For Sun Workshop, use CC to link to bring in C++ runtime
@@ -377,9 +398,8 @@
   
   ## Compiler switch to embed a library name
   LD_SONAME = -h $(MIDDLE_SO_TARGET)
+--- 23,46 ----
   
---- 23,47 ----
-  
   ## Commands to link
   ## For Sun Workshop, use CC to link to bring in C++ runtime
 ! ## For Sun Workshop, -norunpath stops compiler to record a useless RPATH
@@ -393,19 +413,18 @@
   ## Compiler switch to embed a runtime search path
   LD_RPATH=	-R
   LD_RPATH_PRE=	
-  
++ 
 + ## Force RPATH=$ORIGIN to locate own dependencies w/o need for LD_LIBRARY_PATH
 + ENABLE_RPATH=YES
 + RPATHLDFLAGS=${LD_RPATH}'$$ORIGIN'
 + 
 + #SH#	ENABLE_RPATH=YES
 + #SH#	RPATHLDFLAGS="${LD_RPATH}'$$ORIGIN'"
-+ 
+  
   ## Compiler switch to embed a library name
   LD_SONAME = -h $(MIDDLE_SO_TARGET)
-  
 *** misc/icu/source/data/icupkg.inc.in	Fri Apr 19 04:19:16 2002
---- misc/build/icu/source/data/icupkg.inc.in	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/data/icupkg.inc.in	Mon Dec 11 22:58:07 2006
 ***************
 *** 16,22 ****
   include $(top_builddir)/icudefs.mk
@@ -417,7 +436,7 @@
   ICULIBS=$(LIBS) -licu-uc -licu-i18n
 --- 16,21 ----
 *** misc/icu/source/data/makedata.mak	Tue Jun  3 22:52:56 2003
---- misc/build/icu/source/data/makedata.mak	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/data/makedata.mak	Mon Dec 11 22:58:07 2006
 ***************
 *** 27,32 ****
 --- 27,33 ----
@@ -480,7 +499,7 @@
   $(INDEX_RES_FILES):
   	@echo Generating <<res_index.txt
 *** misc/icu/source/data/mappings/ucmcore.mk	Tue Jun  3 22:53:00 2003
---- misc/build/icu/source/data/mappings/ucmcore.mk	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/data/mappings/ucmcore.mk	Mon Dec 11 22:58:07 2006
 ***************
 *** 15,28 ****
   # SJIS (Windows cp932), EUC-JP
@@ -513,7 +532,7 @@
 ! #ibm-943_P14A-1999.ucm ibm-33722_P12A-1999.ucm\
 ! #ibm-970_P110-1995.ucm ibm-949_P11A-1999.ucm ibm-1363_P11B-1998.ucm
 *** misc/icu/source/data/mappings/ucmebcdic.mk	Tue Jun  3 22:53:00 2003
---- misc/build/icu/source/data/mappings/ucmebcdic.mk	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/data/mappings/ucmebcdic.mk	Mon Dec 11 22:58:07 2006
 ***************
 *** 3,27 ****
   # A list of EBCDIC UCM's to build
@@ -568,7 +587,7 @@
 ! #ibm-5123_P100-1999.ucm ibm-803_P100-1999.ucm ibm-8482.ucm\
 ! #ibm-16684_P100-1999.ucm
 *** misc/icu/source/data/mappings/ucmfiles.mk	Tue Jun  3 22:53:00 2003
---- misc/build/icu/source/data/mappings/ucmfiles.mk	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/data/mappings/ucmfiles.mk	Mon Dec 11 22:58:07 2006
 ***************
 *** 25,92 ****
   # ucmebcdic.mk from the <icu>/source/data directory
@@ -709,7 +728,7 @@
 ! #icu-internal-25546.ucm lmb-excp.ucm
   
 *** misc/icu/source/extra/ustdio/ufile.c	Tue Oct  1 03:26:48 2002
---- misc/build/icu/source/extra/ustdio/ufile.c	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/extra/ustdio/ufile.c	Mon Dec 11 22:58:07 2006
 ***************
 *** 89,95 ****
   
@@ -728,7 +747,7 @@
   #else
       result->fFile = f;
 *** misc/icu/source/i18n/tblcoll.cpp	Fri Jun  6 07:05:22 2003
---- misc/build/icu/source/i18n/tblcoll.cpp	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/i18n/tblcoll.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 84,89 ****
 --- 84,101 ----
@@ -751,7 +770,7 @@
                                              UErrorCode& status) :
                                              dataIsOwned(FALSE)
 *** misc/icu/source/i18n/ucol.cpp	Wed Jun 11 01:05:58 2003
---- misc/build/icu/source/i18n/ucol.cpp	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/i18n/ucol.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 512,517 ****
 --- 512,570 ----
@@ -815,7 +834,7 @@
                   int32_t            rulesLength,
                   UColAttributeValue normalizationMode,
 *** misc/icu/source/i18n/ucol_imp.h	Wed Jun 11 23:50:54 2003
---- misc/build/icu/source/i18n/ucol_imp.h	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/i18n/ucol_imp.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 457,462 ****
 --- 457,473 ----
@@ -837,7 +856,7 @@
    * service.
    */
 *** misc/icu/source/i18n/unicode/tblcoll.h	Mon Jun  9 08:13:14 2003
---- misc/build/icu/source/i18n/unicode/tblcoll.h	Thu Aug 31 13:24:31 2006
+--- misc/build/icu/source/i18n/unicode/tblcoll.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 119,124 ****
 --- 119,126 ----
@@ -849,8 +868,24 @@
     /**
      * RuleBasedCollator constructor. This takes the table rules and builds a
      * collation table out of them. Please see RuleBasedCollator class
+*** misc/icu/source/icudefs.mk.in	Tue Jun  3 08:44:40 2003
+--- misc/build/icu/source/icudefs.mk.in	Mon Dec 11 22:58:07 2006
+***************
+*** 136,142 ****
+--- 136,146 ----
+  SHLIB.cc=     $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared
+  
+  # Environment variable to set a runtime search path
++ ifeq ($(OS), IRIX)
++ LDLIBRARYPATH_ENVVAR = LD_LIBRARYN32_PATH
++ else
+  LDLIBRARYPATH_ENVVAR = LD_LIBRARY_PATH
++ endif
+  
+  # Versioned target for a shared library.
+  FINAL_SO_TARGET = $(SO_TARGET).$(SO_TARGET_VERSION)
 *** misc/icu/source/layout/ArabicLayoutEngine.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/ArabicLayoutEngine.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/ArabicLayoutEngine.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 3,8 ****
 --- 3,9 ----
@@ -900,21 +935,21 @@
   
       LE_DELETE_ARRAY(tempChars);
 ***************
-*** 267,272 ****
---- 287,297 ----
+*** 266,271 ****
+--- 286,296 ----
+          success = LE_ILLEGAL_ARGUMENT_ERROR;
           return;
       }
-  
++ 
 + #if 1 // HDU: #105697# TODO: improve handling of deleted/mark glyphs
 +     if( count != glyphCount )
 +         return;
 + #endif
-+ 
+  
       GDEFMarkFilter filter(fGDEFTable);
   
-      // FIXME: we could avoid the memory allocation and copying here by
 *** misc/icu/source/layout/GXLayoutEngine.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/GXLayoutEngine.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/GXLayoutEngine.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 39,45 ****
           return 0;
@@ -933,7 +968,7 @@
       if (LE_FAILURE(success)) {
           return 0;
 *** misc/icu/source/layout/GlyphIterator.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/GlyphIterator.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/GlyphIterator.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 297,302 ****
 --- 297,321 ----
@@ -963,7 +998,7 @@
   {
       if (direction < 0) {
 *** misc/icu/source/layout/GlyphIterator.h	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/GlyphIterator.h	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/GlyphIterator.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 61,68 ****
       void setCurrStreamPosition(le_int32 position);
@@ -986,7 +1021,7 @@
       void setCursiveFirstExitPoint();
       void resetCursiveLastExitPoint();
 *** misc/icu/source/layout/HebrewShaping.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/HebrewShaping.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/HebrewShaping.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 12,22 ****
   U_NAMESPACE_BEGIN
@@ -1016,7 +1051,7 @@
   
   void HebrewShaping::shape(const LEUnicode * /*chars*/, le_int32 /*offset*/, le_int32 charCount, le_int32 /*charMax*/,
 *** misc/icu/source/layout/IndicClassTables.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/IndicClassTables.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/IndicClassTables.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 83,89 ****
   
@@ -1035,7 +1070,7 @@
       _ct, _ct, _ct, _ct, _ct, _ct, _ct, _ct, _ct, _xx, _ct, _ct, _bb, _ct, _ct, _pb, // 09A0 - 09AF
       _rv, _xx, _ct, _xx, _xx, _xx, _ct, _ct, _ct, _ct, _xx, _xx, _nu, _xx, _dr, _dl, // 09B0 - 09BF
 *** misc/icu/source/layout/IndicReordering.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/IndicReordering.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/IndicReordering.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 366,372 ****
   
@@ -1054,8 +1089,8 @@
                   IndicClassTable::CharClass charClass = classTable->getCharClass(ch);
   
                   if (IndicClassTable::isConsonant(charClass)) {
-*** misc/icu/source/layout/KhmerLayoutEngine.cpp	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/KhmerLayoutEngine.cpp	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/KhmerLayoutEngine.cpp	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/KhmerLayoutEngine.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -1144,8 +1179,8 @@
 ! }
 ! 
 ! U_NAMESPACE_END
-*** misc/icu/source/layout/KhmerLayoutEngine.h	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/KhmerLayoutEngine.h	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/KhmerLayoutEngine.h	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/KhmerLayoutEngine.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -1285,8 +1320,8 @@
 ! U_NAMESPACE_END
 ! #endif
 ! 
-*** misc/icu/source/layout/KhmerReordering.cpp	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/KhmerReordering.cpp	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/KhmerReordering.cpp	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/KhmerReordering.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -1822,8 +1857,8 @@
 ! 
 ! 
 ! U_NAMESPACE_END
-*** misc/icu/source/layout/KhmerReordering.h	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/KhmerReordering.h	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/KhmerReordering.h	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/KhmerReordering.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -1963,7 +1998,7 @@
 ! U_NAMESPACE_END
 ! #endif
 *** misc/icu/source/layout/LESwaps.h	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/LESwaps.h	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/LESwaps.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 3,8 ****
 --- 3,9 ----
@@ -1975,7 +2010,7 @@
    */
   
 ***************
-*** 13,35 ****
+*** 13,34 ****
   
   U_NAMESPACE_BEGIN
   
@@ -1998,8 +2033,7 @@
   
   /**
    * This class is used to access data which stored in big endian order
-   * regardless of the conventions of the platform. It has been designed
---- 14,51 ----
+--- 14,50 ----
   
   U_NAMESPACE_BEGIN
   
@@ -2026,20 +2060,19 @@
 !     const le_uint8* p = reinterpret_cast<const le_uint8*>(&rValue);
 !     return ((p[0] << 8) + p[1]);
 ! }
+! 
+! inline le_uint32 loadBigEndianLong( const le_uint32& rValue )
+! {
+!     const le_uint8* p = reinterpret_cast<const le_uint8*>(&rValue);
+!     return ((p[0]<<24) + (p[1]<<16) + (p[2]<<8) + p[3]);
+! }
+! 
+! #endif
   
-+ inline le_uint32 loadBigEndianLong( const le_uint32& rValue )
-+ {
-+     const le_uint8* p = reinterpret_cast<const le_uint8*>(&rValue);
-+     return ((p[0]<<24) + (p[1]<<16) + (p[2]<<8) + p[3]);
-+ }
-+ 
-+ #endif
-+ 
   /**
    * This class is used to access data which stored in big endian order
-   * regardless of the conventions of the platform. It has been designed
 *** misc/icu/source/layout/LayoutEngine.cpp	Thu Jun  5 00:39:18 2003
---- misc/build/icu/source/layout/LayoutEngine.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/LayoutEngine.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 14,19 ****
 --- 14,21 ----
@@ -2062,24 +2095,24 @@
               break;
   
 ***************
-*** 452,457 ****
---- 455,468 ----
+*** 450,455 ****
+--- 453,466 ----
+                  break;
+              }
   
-              break;
-  
++             break;
++ 
 +         case khmrScriptCode:
 +             result = new KhmerOpenTypeLayoutEngine(fontInstance, scriptCode, languageCode, gsubTable);
 +             break;
 + 
 +         case tibtScriptCode:
 +             result = new TibetanLayoutEngine(fontInstance, scriptCode, languageCode, gsubTable);
-+             break;
-+ 
-          default:
-              result = new OpenTypeLayoutEngine(fontInstance, scriptCode, languageCode, gsubTable);
               break;
+  
+          default:
 *** misc/icu/source/layout/LookupProcessor.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/LookupProcessor.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/LookupProcessor.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 92,106 ****
   le_int32 LookupProcessor::selectLookups(const FeatureTable *featureTable, LETag featureTag, le_int32 order)
@@ -2130,7 +2163,7 @@
               featureTable = featureListTable->getFeatureTable(featureIndex, &featureTag);
               count = selectLookups(featureTable, featureTag, order);
 *** misc/icu/source/layout/Makefile.in	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/Makefile.in	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/Makefile.in	Mon Dec 11 22:58:07 2006
 ***************
 *** 52,57 ****
 --- 52,59 ----
@@ -2153,9 +2186,9 @@
   LookupProcessor.o \
   Lookups.o \
 *** misc/icu/source/layout/MarkToBasePosnSubtables.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/MarkToBasePosnSubtables.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/MarkToBasePosnSubtables.cpp	Mon Dec 11 22:58:07 2006
 ***************
-*** 78,84 ****
+*** 78,91 ****
       glyphIterator->setCurrGlyphBaseOffset(baseIterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2163,7 +2196,14 @@
       } else {
           LEPoint baseAdvance;
   
---- 78,84 ----
+          fontInstance->getGlyphAdvance(baseGlyph, pixels);
+          fontInstance->pixelsToUnits(pixels, baseAdvance);
+  
+!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - baseAdvance.fX, anchorDiffY - baseAdvance.fY, -markAdvance.fX, -markAdvance.fY);
+      }
+  
+      return 1;
+--- 78,91 ----
       glyphIterator->setCurrGlyphBaseOffset(baseIterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2171,27 +2211,17 @@
       } else {
           LEPoint baseAdvance;
   
-***************
-*** 85,91 ****
           fontInstance->getGlyphAdvance(baseGlyph, pixels);
           fontInstance->pixelsToUnits(pixels, baseAdvance);
   
-!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - baseAdvance.fX, anchorDiffY - baseAdvance.fY, -markAdvance.fX, -markAdvance.fY);
-      }
-  
-      return 1;
---- 85,91 ----
-          fontInstance->getGlyphAdvance(baseGlyph, pixels);
-          fontInstance->pixelsToUnits(pixels, baseAdvance);
-  
 !         glyphIterator->setCurrGlyphPositionAdjustment(anchorDiffX - baseAdvance.fX, anchorDiffY - baseAdvance.fY, -markAdvance.fX, -markAdvance.fY);
       }
   
       return 1;
 *** misc/icu/source/layout/MarkToLigaturePosnSubtables.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/MarkToLigaturePosnSubtables.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/MarkToLigaturePosnSubtables.cpp	Mon Dec 11 22:58:07 2006
 ***************
-*** 89,95 ****
+*** 89,102 ****
       glyphIterator->setCurrGlyphBaseOffset(ligatureIterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2199,7 +2229,14 @@
       } else {
           LEPoint ligatureAdvance;
   
---- 89,95 ----
+          fontInstance->getGlyphAdvance(ligatureGlyph, pixels);
+          fontInstance->pixelsToUnits(pixels, ligatureAdvance);
+  
+!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - ligatureAdvance.fX, anchorDiffY - ligatureAdvance.fY, -markAdvance.fX, -markAdvance.fY);
+      }
+  
+      return 1;
+--- 89,102 ----
       glyphIterator->setCurrGlyphBaseOffset(ligatureIterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2207,27 +2244,17 @@
       } else {
           LEPoint ligatureAdvance;
   
-***************
-*** 96,102 ****
           fontInstance->getGlyphAdvance(ligatureGlyph, pixels);
           fontInstance->pixelsToUnits(pixels, ligatureAdvance);
   
-!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - ligatureAdvance.fX, anchorDiffY - ligatureAdvance.fY, -markAdvance.fX, -markAdvance.fY);
-      }
-  
-      return 1;
---- 96,102 ----
-          fontInstance->getGlyphAdvance(ligatureGlyph, pixels);
-          fontInstance->pixelsToUnits(pixels, ligatureAdvance);
-  
 !         glyphIterator->setCurrGlyphPositionAdjustment(anchorDiffX - ligatureAdvance.fX, anchorDiffY - ligatureAdvance.fY, -markAdvance.fX, -markAdvance.fY);
       }
   
       return 1;
 *** misc/icu/source/layout/MarkToMarkPosnSubtables.cpp	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/MarkToMarkPosnSubtables.cpp	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/MarkToMarkPosnSubtables.cpp	Mon Dec 11 22:58:07 2006
 ***************
-*** 78,84 ****
+*** 78,91 ****
       glyphIterator->setCurrGlyphBaseOffset(mark2Iterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2235,7 +2262,14 @@
       } else {
           LEPoint mark2Advance;
   
---- 78,84 ----
+          fontInstance->getGlyphAdvance(mark2Glyph, pixels);
+          fontInstance->pixelsToUnits(pixels, mark2Advance);
+  
+!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - mark2Advance.fX, anchorDiffY - mark2Advance.fY, -markAdvance.fX, -markAdvance.fY);
+      }
+  
+      return 1;
+--- 78,91 ----
       glyphIterator->setCurrGlyphBaseOffset(mark2Iterator.getCurrStreamPosition());
   
       if (glyphIterator->isRightToLeft()) {
@@ -2243,25 +2277,15 @@
       } else {
           LEPoint mark2Advance;
   
-***************
-*** 85,91 ****
           fontInstance->getGlyphAdvance(mark2Glyph, pixels);
           fontInstance->pixelsToUnits(pixels, mark2Advance);
   
-!         glyphIterator->adjustCurrGlyphPositionAdjustment(anchorDiffX - mark2Advance.fX, anchorDiffY - mark2Advance.fY, -markAdvance.fX, -markAdvance.fY);
-      }
-  
-      return 1;
---- 85,91 ----
-          fontInstance->getGlyphAdvance(mark2Glyph, pixels);
-          fontInstance->pixelsToUnits(pixels, mark2Advance);
-  
 !         glyphIterator->setCurrGlyphPositionAdjustment(anchorDiffX - mark2Advance.fX, anchorDiffY - mark2Advance.fY, -markAdvance.fX, -markAdvance.fY);
       }
   
       return 1;
 *** misc/icu/source/layout/OpenTypeLayoutEngine.h	Tue Jun  3 22:58:22 2003
---- misc/build/icu/source/layout/OpenTypeLayoutEngine.h	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/OpenTypeLayoutEngine.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 319,324 ****
 --- 319,337 ----
@@ -2284,8 +2308,8 @@
           return tempGlyphCount;
       };
   
-*** misc/icu/source/layout/TibetanLayoutEngine.cpp	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/TibetanLayoutEngine.cpp	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/TibetanLayoutEngine.cpp	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/TibetanLayoutEngine.cpp	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -2394,8 +2418,8 @@
 ! }
 ! 
 ! U_NAMESPACE_END
-*** misc/icu/source/layout/TibetanLayoutEngine.h	Thu Aug 31 13:28:01 2006
---- misc/build/icu/source/layout/TibetanLayoutEngine.h	Thu Aug 31 13:24:32 2006
+*** misc/icu/source/layout/TibetanLayoutEngine.h	Mon Dec 11 22:58:49 2006
+--- misc/build/icu/source/layout/TibetanLayoutEngine.h	Mon Dec 11 22:58:07 2006
 ***************
 *** 1 ****
 ! dummy
@@ -2614,10 +2638,10 @@
 ! #endif
 ! 
 *** misc/icu/source/layout/layout.vcproj	Thu May  1 00:50:20 2003
---- misc/build/icu/source/layout/layout.vcproj	Thu Aug 31 13:24:32 2006
+--- misc/build/icu/source/layout/layout.vcproj	Mon Dec 11 22:58:08 2006
 ***************
-*** 215,220 ****
---- 215,223 ----
+*** 215,226 ****
+--- 215,232 ----
   				RelativePath=".\IndicLayoutEngine.cpp">
   			</File>
   			<File
@@ -2627,9 +2651,6 @@
   				RelativePath=".\IndicRearrangementProcessor.cpp">
   			</File>
   			<File
-***************
-*** 221,226 ****
---- 224,232 ----
   				RelativePath=".\IndicReordering.cpp">
   			</File>
   			<File
@@ -2652,19 +2673,19 @@
   			</File>
   			<File
 ***************
-*** 426,431 ****
---- 435,443 ----
-  				RelativePath=".\IndicReordering.h">
+*** 424,429 ****
+--- 433,441 ----
   			</File>
   			<File
-+ 				RelativePath=".\KhmerReordering.h">
+  				RelativePath=".\IndicReordering.h">
 + 			</File>
 + 			<File
++ 				RelativePath=".\KhmerReordering.h">
+  			</File>
+  			<File
   				RelativePath=".\LEFontInstance.h">
-  				<FileConfiguration
-  					Name="Debug|Win32">
 *** misc/icu/source/layout/layoutobj.inc	Tue Nov 14 23:15:30 2000
---- misc/build/icu/source/layout/layoutobj.inc	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/layout/layoutobj.inc	Mon Dec 11 22:58:08 2006
 ***************
 *** 8,13 ****
 --- 8,14 ----
@@ -2685,8 +2706,60 @@
   LigatureSubstitutionSubtables.o \
   LookupProcessor.o \
   Lookups.o \
+*** misc/icu/source/stubdata/stubdata.c	Wed Nov 21 03:28:14 2001
+--- misc/build/icu/source/stubdata/stubdata.c	Mon Dec 11 23:01:05 2006
+***************
+*** 28,41 ****
+      UDataInfo info;
+      char padding[8];
+      uint32_t count, reserved;
+-     /*
+      const struct {
+      const char *const name; 
+      const void *const data;
+!     } toc[1];
+!     */
+!    int   fakeNameAndData[4];       /* TODO:  Change this header type from */
+!                                    /*        pointerTOC to OffsetTOC.     */
+  } ICU_Data_Header;
+  
+  U_EXPORT const ICU_Data_Header U_ICUDATA_ENTRY_POINT = {
+--- 28,37 ----
+      UDataInfo info;
+      char padding[8];
+      uint32_t count, reserved;
+      const struct {
+      const char *const name; 
+      const void *const data;
+!     } toc[295];	/* set to real toc size to avoid symbol size mismatch runtime link errors */
+  } ICU_Data_Header;
+  
+  U_EXPORT const ICU_Data_Header U_ICUDATA_ENTRY_POINT = {
+***************
+*** 64,73 ****
+      0,                  /* count        */
+      0,                  /* Reserved     */
+      {                   /*  TOC structure */
+! /*        {    */
+!           0 , 0 , 0, 0  /* name and data entries.  Count says there are none,  */
+                          /*  but put one in just in case.                       */
+! /*        }  */
+      }
+  };
+  
+--- 60,69 ----
+      0,                  /* count        */
+      0,                  /* Reserved     */
+      {                   /*  TOC structure */
+!           {
+!                 {0 , 0} /* name and data entries.  Count says there are none,  */
+                          /*  but put one in just in case.                       */
+!           }
+      }
+  };
+  
 *** misc/icu/source/test/ieeetest/ieeetest.cpp	Wed Mar 21 20:46:50 2001
---- misc/build/icu/source/test/ieeetest/ieeetest.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/ieeetest/ieeetest.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 13,23 ****
   *******************************************************************************
@@ -2713,7 +2786,7 @@
   
   //==============================
 *** misc/icu/source/test/intltest/loctest.cpp	Thu Jun  5 01:56:50 2003
---- misc/build/icu/source/test/intltest/loctest.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/loctest.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 4,9 ****
 --- 4,10 ----
@@ -2725,7 +2798,7 @@
   #include <stdio.h>
   #include <string.h>
 *** misc/icu/source/test/intltest/testidn.cpp	Mon Jun  9 06:54:46 2003
---- misc/build/icu/source/test/intltest/testidn.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/testidn.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 19,27 ****
   *   in various IDNA conversion processes.
@@ -2748,7 +2821,7 @@
   #if !UCONFIG_NO_IDNA && !UCONFIG_NO_TRANSLITERATION
   
 *** misc/icu/source/test/intltest/tsmutex.cpp	Fri May 24 01:56:48 2002
---- misc/build/icu/source/test/intltest/tsmutex.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/tsmutex.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 4,9 ****
 --- 4,10 ----
@@ -2760,7 +2833,7 @@
   #include <stdio.h>
   #include <string.h>
 *** misc/icu/source/test/intltest/tsputil.cpp	Fri Oct  5 20:47:10 2001
---- misc/build/icu/source/test/intltest/tsputil.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/tsputil.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 4,9 ****
 --- 4,10 ----
@@ -2772,7 +2845,7 @@
   
   #include <float.h> // DBL_MAX, DBL_MIN
 *** misc/icu/source/test/intltest/uobjtest.cpp	Tue Jun  3 22:56:50 2003
---- misc/build/icu/source/test/intltest/uobjtest.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/uobjtest.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 4,9 ****
 --- 4,10 ----
@@ -2784,7 +2857,7 @@
   #include <string.h>
   
 *** misc/icu/source/test/intltest/ustrtest.cpp	Fri May  9 18:15:50 2003
---- misc/build/icu/source/test/intltest/ustrtest.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/test/intltest/ustrtest.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 4,9 ****
 --- 4,10 ----
@@ -2796,7 +2869,7 @@
   #include "unicode/unistr.h"
   #include "unicode/uchar.h"
 *** misc/icu/source/tools/genbrk/genbrk.cpp	Tue Jun  3 22:56:52 2003
---- misc/build/icu/source/tools/genbrk/genbrk.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/genbrk/genbrk.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 26,33 ****
   //
@@ -2817,7 +2890,7 @@
   #include "unicode/unistr.h"
   #include "unicode/rbbi.h"
 *** misc/icu/source/tools/gennorm/gennorm.c	Tue May  6 03:36:14 2003
---- misc/build/icu/source/tools/gennorm/gennorm.c	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/gennorm/gennorm.c	Mon Dec 11 22:58:08 2006
 ***************
 *** 241,249 ****
               return;
@@ -2840,7 +2913,7 @@
           } else {
               return;
 *** misc/icu/source/tools/genpname/genpname.cpp	Wed Jun  4 00:23:50 2003
---- misc/build/icu/source/tools/genpname/genpname.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/genpname/genpname.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 8,16 ****
   **********************************************************************
@@ -2863,7 +2936,7 @@
   #include "cmemory.h"
   #include "cstring.h"
 *** misc/icu/source/tools/gentz/gentz.cpp	Tue Jun  3 22:56:54 2003
---- misc/build/icu/source/tools/gentz/gentz.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/gentz/gentz.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 25,33 ****
    * See tz.pl for the file format that is READ by this program.
@@ -2886,7 +2959,7 @@
   #include "cmemory.h"
   #include "cstring.h"
 *** misc/icu/source/tools/genuca/genuca.cpp	Tue Jun  3 22:56:54 2003
---- misc/build/icu/source/tools/genuca/genuca.cpp	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/genuca/genuca.cpp	Mon Dec 11 22:58:08 2006
 ***************
 *** 23,30 ****
   *   05/09/2001  weiv                    Case bits are now in the CEs, not in front
@@ -2907,7 +2980,7 @@
   #include "ucol_imp.h"
   #include "genuca.h"
 *** misc/icu/source/tools/pkgdata/dllmode.c	Tue Jun  3 22:56:54 2003
---- misc/build/icu/source/tools/pkgdata/dllmode.c	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/pkgdata/dllmode.c	Mon Dec 11 22:58:08 2006
 ***************
 *** 131,137 ****
       }
@@ -2960,7 +3033,7 @@
   #else
       
 *** misc/icu/source/tools/pkgdata/gmake.c	Tue Aug  6 21:06:32 2002
---- misc/build/icu/source/tools/pkgdata/gmake.c	Thu Aug 31 13:24:33 2006
+--- misc/build/icu/source/tools/pkgdata/gmake.c	Mon Dec 11 22:58:08 2006
 ***************
 *** 203,209 ****
         commands = pkg_appendToList(commands, NULL, uprv_strdup(stanza));
@@ -2978,45 +3051,3 @@
       commands = pkg_appendToList(commands, NULL, uprv_strdup(stanza));
   
       sprintf(stanza, "@$(RMV) $(TEMP_DIR)/%s", cfile+genFileOffset);
-*** misc/icu/source/common/unicode/urename.h
---- misc/build/icu/source/common/unicode/urename.h
-***************
-*** 25,31 ****
-     that do not use Autoconf. */
-  /* #define U_DISABLE_RENAMING 1 */
-  
-! #if !U_DISABLE_RENAMING
-  
-  /* C exports renaming data */
-  
---- 25,31 ----
-     that do not use Autoconf. */
-  /* #define U_DISABLE_RENAMING 1 */
-  
-! #if !defined U_DISABLE_RENAMING || !U_DISABLE_RENAMING
-  
-  /* C exports renaming data */
-  
-*** misc/icu/source/common/unicode/utypes.h
---- misc/build/icu/source/common/unicode/utypes.h
-***************
-*** 420,428 ****
-   *
-   * Note: This is currently only done on Windows because
-   * some Linux/Unix compilers have problems with defining global new/delete.
-!  * On Windows, WIN32 is defined, and it is _MSC_Ver>=1200 for MSVC 6.0 and higher.
-   */
-! #if defined(XP_CPLUSPLUS) && defined(WIN32) && (_MSC_Ver>=1200) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_USTDIO_IMPLEMENTATION))
-  
-  /**
-   * Global operator new, defined only inside ICU4C, must not be used.
---- 420,428 ----
-   *
-   * Note: This is currently only done on Windows because
-   * some Linux/Unix compilers have problems with defining global new/delete.
-!  * On Windows, WIN32 is defined, and it is _MSC_VER>=1200 for MSVC 6.0 and higher.
-   */
-! #if defined(XP_CPLUSPLUS) && defined(WIN32) && (_MSC_VER>=1200) && (defined(U_COMMON_IMPLEMENTATION) || defined(U_I18N_IMPLEMENTATION) || defined(U_LAYOUT_IMPLEMENTATION) || defined(U_USTDIO_IMPLEMENTATION))
-  
-  /**
-   * Global operator new, defined only inside ICU4C, must not be used.
