480323 add code to plug in ICU converters by default
This is not configured in by default but after some serious massaging
incorporate that patch from Chromium/Chrome.
diff --git a/win32/configure.js b/win32/configure.js
index 3c960a6..342fd9d 100644
--- a/win32/configure.js
+++ b/win32/configure.js
@@ -40,6 +40,7 @@
var withXptr = true;
var withXinclude = true;
var withIconv = true;
+var withIcu = false;
var withIso8859x = false;
var withZlib = false;
var withDebug = true;
@@ -124,6 +125,7 @@
txt += " xptr: Enable XPointer support (" + (withXptr? "yes" : "no") + ")\n";
txt += " xinclude: Enable XInclude support (" + (withXinclude? "yes" : "no") + ")\n";
txt += " iconv: Enable iconv support (" + (withIconv? "yes" : "no") + ")\n";
+ txt += " icu: Enable icu support (" + (withIcu? "yes" : "no") + ")\n";
txt += " iso8859x: Enable ISO8859X support (" + (withIso8859x? "yes" : "no") + ")\n";
txt += " zlib: Enable zlib support (" + (withZlib? "yes" : "no") + ")\n";
txt += " xml_debug: Enable XML debbugging module (" + (withDebug? "yes" : "no") + ")\n";
@@ -233,6 +235,7 @@
vf.WriteLine("WITH_XPTR=" + (withXptr? "1" : "0"));
vf.WriteLine("WITH_XINCLUDE=" + (withXinclude? "1" : "0"));
vf.WriteLine("WITH_ICONV=" + (withIconv? "1" : "0"));
+ vf.WriteLine("WITH_ICU=" + (withIcu? "1" : "0"));
vf.WriteLine("WITH_ISO8859X=" + (withIso8859x? "1" : "0"));
vf.WriteLine("WITH_ZLIB=" + (withZlib? "1" : "0"));
vf.WriteLine("WITH_DEBUG=" + (withDebug? "1" : "0"));
@@ -319,6 +322,8 @@
of.WriteLine(s.replace(/\@WITH_XINCLUDE\@/, withXinclude? "1" : "0"));
} else if (s.search(/\@WITH_ICONV\@/) != -1) {
of.WriteLine(s.replace(/\@WITH_ICONV\@/, withIconv? "1" : "0"));
+ } else if (s.search(/\@WITH_ICU\@/) != -1) {
+ of.WriteLine(s.replace(/\@WITH_ICU\@/, withIcu? "1" : "0"));
} else if (s.search(/\@WITH_ISO8859X\@/) != -1) {
of.WriteLine(s.replace(/\@WITH_ISO8859X\@/, withIso8859x? "1" : "0"));
} else if (s.search(/\@WITH_ZLIB\@/) != -1) {
@@ -462,6 +467,8 @@
withXinclude = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "iconv")
withIconv = strToBool(arg.substring(opt.length + 1, arg.length));
+ else if (opt == "icu")
+ withIcu = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "iso8859x")
withIso8859x = strToBool(arg.substring(opt.length + 1, arg.length));
else if (opt == "zlib")
@@ -611,7 +618,13 @@
makefile = ".\\Makefile.mingw";
else if (compiler == "bcb")
makefile = ".\\Makefile.bcb";
-fso.CopyFile(makefile, ".\\Makefile", true);
+var new_makefile = ".\\Makefile";
+var f = fso.FileExists(new_makefile);
+if (f) {
+ var t = fso.GetFile(new_makefile);
+ t.Attributes =0;
+}
+fso.CopyFile(makefile, new_makefile, true);
WScript.Echo("Created Makefile.");
// Create the config.h.
var confighsrc = "..\\include\\win32config.h";
@@ -640,6 +653,7 @@
txtOut += " XPointer support: " + boolToStr(withXptr) + "\n";
txtOut += " XInclude support: " + boolToStr(withXinclude) + "\n";
txtOut += " iconv support: " + boolToStr(withIconv) + "\n";
+txtOut += " icu support: " + boolToStr(withIcu) + "\n";
txtOut += " iso8859x support: " + boolToStr(withIso8859x) + "\n";
txtOut += " zlib support: " + boolToStr(withZlib) + "\n";
txtOut += " Debugging module: " + boolToStr(withDebug) + "\n";