sync master with lastest vba changes
[ooovba.git] / icu / icu-4.0.patch
blobcb46b9c71cae30755a4b491371f416ea53d865f7
1 --- misc/icu/source/common/putil.c 2008-07-01 03:41:12.000000000 +0200
2 +++ misc/build/icu/source/common/putil.c 2008-09-02 07:01:29.335795765 +0200
3 @@ -52,7 +52,7 @@
4 Poorly upgraded Solaris machines can't have this defined.
5 Cleanly installed Solaris can use this #define.
6 */
7 -#if !defined(_XOPEN_SOURCE_EXTENDED) && (!defined(__STDC_VERSION__) || __STDC_VERSION__ >= 199901L)
8 +#if !defined(_XOPEN_SOURCE_EXTENDED) && (!defined(__STDC_VERSION__) || __STDC_VERSION__ < 199901L)
9 #define _XOPEN_SOURCE_EXTENDED 1
10 #endif
12 --- misc/icu/source/config/mh-darwin Tue Jul 1 03:41:24 2008
13 +++ misc/build/icu/source/config/mh-darwin Tue Jan 20 18:33:16 2009
14 @@ -25,7 +25,7 @@
15 SHLIB.cc= $(CXX) -dynamiclib -dynamic $(CXXFLAGS) $(LDFLAGS)
17 ## Compiler switches to embed a library name and version information
18 -LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name $(notdir $(MIDDLE_SO_TARGET))
19 +LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name @executable_path/$(notdir $(FINAL_SO_TARGET))
21 ## Compiler switch to embed a runtime search path
22 LD_RPATH=
23 @@ -41,10 +41,6 @@
24 ## Non-shared intermediate object suffix
25 STATIC_O = ao
27 -## Override Versioned target for a shared library.
28 -FINAL_SO_TARGET= $(basename $(SO_TARGET)).$(SO_TARGET_VERSION).$(SO)
29 -MIDDLE_SO_TARGET= $(basename $(SO_TARGET)).$(SO_TARGET_VERSION_MAJOR).$(SO)
31 ## Compilation rules
32 %.$(STATIC_O): $(srcdir)/%.c
33 $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $<
34 @@ -76,15 +72,9 @@
36 ## Versioned libraries rules
38 -%.$(SO_TARGET_VERSION_MAJOR).$(SO): %.$(SO_TARGET_VERSION).$(SO)
39 +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION)
40 $(RM) $@ && ln -s ${<F} $@
41 -%.$(SO): %.$(SO_TARGET_VERSION_MAJOR).$(SO)
42 - $(RM) $@ && ln -s ${*F}.$(SO_TARGET_VERSION).$(SO) $@
44 -# tzcode option
45 -TZORIG_EXTRA_CFLAGS=-DSTD_INSPIRED
47 -# genren opts
48 -GENREN_PL_OPTS=-x Mach-O -n '-g' -p '| c++filt'
49 +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR)
50 + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@
52 ## End Darwin-specific setup
53 --- misc/icu/source/config/mh-linux 2007-12-12 19:57:36.000000000 +0100
54 +++ misc/build/icu/source/config/mh-linux 2008-05-21 18:59:13.000000000 +0200
55 @@ -20,6 +20,14 @@
56 LD_RPATH=
57 LD_RPATH_PRE = -Wl,-rpath,
59 +## Force RPATH=$ORIGIN to locate own dependencies w/o need for LD_LIBRARY_PATH
60 +## (incl. the C++ runtime libs potentially found in the URE lib dir):
61 +ENABLE_RPATH=YES
62 +RPATHLDFLAGS=${LD_RPATH_PRE}'$$ORIGIN:$$ORIGIN/../ure-link/lib'
64 +#SH# ENABLE_RPATH=YES
65 +#SH# RPATHLDFLAGS="${LD_RPATH_PRE}'$$ORIGIN:$$ORIGIN/../ure-link/lib'"
67 ## These are the library specific LDFLAGS
68 LDFLAGSICUDT=-nodefaultlibs -nostdlib
70 --- misc/icu/source/config/mh-mingw 2008-07-01 10:41:24.000000000 +0900
71 +++ misc/build/icu/source/config/mh-mingw 2008-11-06 00:18:30.261250000 +0900
72 @@ -72,10 +72,12 @@
73 # The #M# is used to delete lines for icu-config
74 # Current full path directory.
75 #CURR_FULL_DIR=$(shell pwd -W)#M# for MSYS
76 -CURR_FULL_DIR=$(subst \,/,$(shell cmd /c cd | tail --bytes=+3))#M# for Cygwin shell
77 +CURR_FULL_DIR=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell
78 # Current full path directory for use in source code in a -D compiler option.
79 #CURR_SRCCODE_FULL_DIR=$(subst /,\\\\,$(shell pwd -W))#M# for MSYS
80 -CURR_SRCCODE_FULL_DIR=$(subst \,/,$(shell cmd /c cd | tail --bytes=+3))#M# for Cygwin shell
81 +CURR_SRCCODE_FULL_DIR=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell
82 +SRCDIR_DEPEND=$(shell cd $(SRCDIR) && pwd)
83 +DATAFILEPATHS_DEPEND=$(foreach p,$(DATAFILEPATHS),$(shell cd $(dir $(p)) && pwd)/$(notdir $(p)))
85 ## Compilation rules
86 %.$(STATIC_O): $(srcdir)/%.c
87 --- misc/icu/source/config/mh-solaris 2008-07-01 03:41:26.000000000 +0200
88 +++ misc/build/icu/source/config/mh-solaris 2009-02-17 11:54:45.105890123 +0100
89 @@ -18,17 +18,24 @@
91 ## Commands to link
92 ## For Sun Workshop, use CC to link to bring in C++ runtime
93 -LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS)
94 -LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS)
95 +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) -norunpath
96 +LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -norunpath
98 ## Commands to make a shared library
99 SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -G
100 -SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -G
101 +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -G -norunpath
103 ## Compiler switch to embed a runtime search path
104 LD_RPATH= -R
105 LD_RPATH_PRE=
107 +## Force RPATH=$ORIGIN to locate own dependencies w/o need for LD_LIBRARY_PATH
108 +ENABLE_RPATH=YES
109 +RPATHLDFLAGS=${LD_RPATH}'$$ORIGIN'
111 +#SH# ENABLE_RPATH=YES
112 +#SH# RPATHLDFLAGS="${LD_RPATH}'$$ORIGIN'"
114 #LIBRARY_PATH_PREFIX=/usr/lib/lwp:
116 ## Compiler switch to embed a library name
117 --- misc/icu/source/layout/ArabicShaping.cpp 2008-07-01 03:42:04.000000000 +0200
118 +++ misc/build/icu/source/layout/ArabicShaping.cpp 2009-02-17 12:04:34.264869737 +0100
119 @@ -79,7 +79,6 @@
120 #define markFeatureMask 0x00040000UL
121 #define mkmkFeatureMask 0x00020000UL
123 -#define NO_FEATURES 0
124 #define ISOL_FEATURES (isolFeatureMask | ligaFeatureMask | msetFeatureMask | markFeatureMask | ccmpFeatureMask | rligFeatureMask | caltFeatureMask | dligFeatureMask | cswhFeatureMask | cursFeatureMask | kernFeatureMask | mkmkFeatureMask)
126 #define SHAPE_MASK 0xF0000000UL
127 @@ -174,11 +173,7 @@
128 LEUnicode c = chars[in];
129 ShapeType t = getShapeType(c);
131 - if (t == ST_NOSHAPE_NONE) {
132 - glyphStorage.setAuxData(out, NO_FEATURES, success);
133 - } else {
134 - glyphStorage.setAuxData(out, ISOL_FEATURES, success);
136 + glyphStorage.setAuxData(out, ISOL_FEATURES, success);
138 if ((t & MASK_TRANSPARENT) != 0) {
139 continue;
140 --- misc/icu/source/layoutex/ParagraphLayout.cpp 2008-07-01 03:42:02.000000000 +0200
141 +++ misc/build/icu/source/layoutex/ParagraphLayout.cpp 2008-12-01 19:32:58.000000000 +0100
142 @@ -868,7 +868,7 @@
144 return nullLanguageCode;
146 -#elif
147 +#else
149 // TODO - dummy implementation for right now...
150 le_int32 ParagraphLayout::getLanguageCode(const Locale *locale)
151 --- misc/icu/source/tools/pkgdata/cmnmode.c 2008-07-01 10:41:20.000000000 +0900
152 +++ misc/build/icu/source/tools/pkgdata/cmnmode.c 2008-11-07 00:03:32.393500000 +0900
153 @@ -69,7 +69,11 @@
154 sprintf(tmp, "# List file for gencmn:\n"
155 "CMNLIST=%s%s%s_common.lst\n\n",
156 o->tmpDir,
157 +#ifdef __MINGW32__
158 + U_FILE_ALT_SEP_STRING,
159 +#else
160 U_FILE_SEP_STRING,
161 +#endif
162 o->shortName);
163 T_FileStream_writeLine(makefile, tmp);
165 --- misc/icu/source/tools/pkgdata/dllmode.c 2008-07-01 10:41:20.000000000 +0900
166 +++ misc/build/icu/source/tools/pkgdata/dllmode.c 2008-11-07 06:08:36.016750000 +0900
167 @@ -139,7 +139,11 @@
168 sprintf(tmp, "# List file for gencmn:\n"
169 "CMNLIST=%s%s$(NAME)_dll.lst\n\n",
170 o->tmpDir,
171 +#ifdef __MINGW32__
172 + U_FILE_ALT_SEP_STRING);
173 +#else
174 U_FILE_SEP_STRING);
175 +#endif
176 T_FileStream_writeLine(makefile, tmp);
178 if(o->hadStdin == FALSE) { /* shortcut */
179 --- misc/icu/source/tools/pkgdata/make.c 2008-07-01 10:41:20.000000000 +0900
180 +++ misc/build/icu/source/tools/pkgdata/make.c 2008-11-06 23:23:04.096625000 +0900
181 @@ -313,8 +313,13 @@
182 uprv_strcpy(cfile+uprv_strlen(cfile)-uprv_strlen(objSuffix), ".c" ); /* replace .o with .c */
184 /* Make up parents.. */
185 +#ifdef __MINGW32__
186 + parentPath = uprv_malloc(1+uprv_strlen(baseName) + uprv_strlen("$(SRCDIR_DEPEND)/"));
187 + sprintf(parentPath, "$(SRCDIR_DEPEND)/%s", baseName);
188 +#else
189 parentPath = uprv_malloc(1+uprv_strlen(baseName) + uprv_strlen("$(SRCDIR)/"));
190 sprintf(parentPath, "$(SRCDIR)/%s", baseName);
191 +#endif
192 parents = pkg_appendToList(parents, NULL, parentPath);
194 /* make up commands.. */
195 @@ -379,7 +384,11 @@
196 T_FileStream_writeLine(f, "\n");
197 T_FileStream_writeLine(f, "BASE_OBJECTS=$(NAME)_dat.o\n");
198 T_FileStream_writeLine(f, "\n");
199 +#ifdef __MINGW32__
200 + T_FileStream_writeLine(f, "$(TEMP_DIR)/$(NAME).dat: $(CMNLIST) $(DATAFILEPATHS_DEPEND)\n");
201 +#else
202 T_FileStream_writeLine(f, "$(TEMP_DIR)/$(NAME).dat: $(CMNLIST) $(DATAFILEPATHS)\n");
203 +#endif
204 T_FileStream_writeLine(f, "\t$(INVOKE) $(ICUPKG) -t$(ICUDATA_CHAR) -c -s $(SRCDIR) -a $(CMNLIST) new $(TEMP_DIR)/$(CNAME).dat\n");
205 T_FileStream_writeLine(f, "\n");
206 T_FileStream_writeLine(f, "$(TEMP_DIR)/$(NAME)_dat.o : $(TEMP_DIR)/$(NAME).dat\n");
207 --- misc/icu/source/tools/pkgdata/pkgdata.c 2008-07-01 10:41:20.000000000 +0900
208 +++ misc/build/icu/source/tools/pkgdata/pkgdata.c 2008-11-07 05:59:27.110500000 +0900
209 @@ -594,7 +594,11 @@
210 exit(U_ILLEGAL_ARGUMENT_ERROR);
212 uprv_strcpy(tmp, o->srcDir);
213 +#ifdef __MINGW32__
214 + uprv_strcat(tmp, o->srcDir[uprv_strlen(o->srcDir)-1]==U_FILE_SEP_CHAR?"":U_FILE_ALT_SEP_STRING);
215 +#else
216 uprv_strcat(tmp, o->srcDir[uprv_strlen(o->srcDir)-1]==U_FILE_SEP_CHAR?"":U_FILE_SEP_STRING);
217 +#endif
218 uprv_strcat(tmp, s);
219 o->filePaths = pkg_appendToList(o->filePaths, &tail2, uprv_strdup(tmp));
220 linePtr = lineNext;
221 --- misc/icu/source/tools/pkgdata/sttcmode.c 2008-07-01 10:41:20.000000000 +0900
222 +++ misc/build/icu/source/tools/pkgdata/sttcmode.c 2008-11-07 00:30:05.690375000 +0900
223 @@ -172,7 +172,11 @@
224 sprintf(tmp, "# List file for gencmn:\n"
225 "CMNLIST=%s%s$(NAME)_static.lst\n\n",
226 o->tmpDir,
227 +#ifdef __MINGW32__
228 + U_FILE_ALT_SEP_STRING);
229 +#else
230 U_FILE_SEP_STRING);
231 +#endif
232 T_FileStream_writeLine(makefile, tmp);
234 if(o->hadStdin == FALSE) { /* shortcut */