blob: fa310eabf240bc40902d369a1fd3dfa36dda4793 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="">
* Copyright (C) 2000-2006, International Business Machines Corporation and *
* others. All Rights Reserved. *
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="COPYRIGHT" content="Copyright (c) 2007 IBM Corporation and others. All Rights Reserved.">
<meta name="keywords" content="ICUTZU, ICU4J Time Zone Update Utility" />
<title>ICU4J Time Zone Update Utility (ICUTZU)</title>
<link rel="stylesheet" href="icu.css" type="text/css">
<h2>ICU4J Time Zone Update Utility (ICUTZU)</h2>
<li><a href="#intro">Introduction</a></li>
<li><a href="#sysreq">System Requirements</a></li>
<li><a href="#install">Installation</a></li>
<li><a href="#run">Running ICUTZU</a>
<li><a href="#gui">Running in GUI Mode</a></li>
<li><a href="#cmd">Running in Command-line Mode</a></li>
<li><a href="#restore">Restoring Changes</a></li>
<a name="intro"><h3>Introduction</h3></a>
<!-- any changes to the introduction should also be done in /repos/icuproj/trunk/htdocs/download/icutzu.html -->
<p>ICU4J Time Zone Update Utility (ICUTZU) is a utility that supplies ICU4J jar files with the latest time zone information and daylight savings time changeover dates.</p>
<p>The time zone data is stored in zoneinfo.res files which are generated by the ICU team using the Olson Time Zone Database (<a href=""></a>). Every version of the time zone data corresponds directly to a version of the Olson database. For example "2006a" refers to the first refresh of the Olson database in 2006.</p>
<p>ICUTZU works by searching the file system for ICU4J jar files containing old time zone data, checking online for the newest time zone data and updating the ICU4J jar files accordingly. The user can choose to update from a copy of the time zone data that comes bundled with ICUTZU or from an online copy on the ICU servers.</p>
<a name="sysreq"><h3>System Requirements</h3></a>
<p>ICUTZU will run on any system that ICU4J runs on: Solaris 5.9, 5.10, AIX 5.2, 5.3, RHEL 4, 5, Windows XP, Vista, HP-UX 9000.</p>
<p>ICUTZU also requires Java 1.3 or higher to be installed.</p>
<a name="install"><h3>Installation</h3></a>
<!-- any changes to the installation should also be done in /repos/icuproj/trunk/htdocs/download/icutzu.html -->
<p>Unpack the archive into a directory of your choosing. For Unix-based systems, you will need to set permissions on</p>
<p><code>chmod 755</code></p>
<a name="run"><h3>Running ICUTZU</h3></a>
<a name="gui"><h4>Running in GUI Mode</h4></a>
<li><p>To start ICUTZU, double-click <b>icutzu.jar</b> or open a console and type <code>java -jar icutzu.jar</code> .</p></li>
<p>Specify which paths to search and which paths to exclude from the search. By default, all drives are included in the search.</p>
<li><p>To include a path in the search, select <b>Include</b> from the drop-down menu, and either type the path in the text field and press enter, or simply browse for the path.</p></li>
<li><p>To exclude a path from the search, do the same as above, but select <b>Exclude</b> from the drop-down menu.</p></li>
<li><p>To specify whether to search subdirectories, check or uncheck the "Search Subdirectories" option.</p></li>
<li><p>For additional options, right-click the directory list for a context-menu.</p></li>
<li><p>Click <b>Search</b> to begin searching for updatable ICU4J jar files in the directories specified. A new window will pop up during the search with a list of updatable ICU4J jar files found.</p></li>
<p>Select which ICU4J jar files you wish to update.</p>
<ul><li><p><b>ICU Version</b> refers to the version of the ICU4J jar file itself, and <b>TZ Version</b> refers to version of the time zone data within the jar file.</p></li></ul>
<li><p>Choose the version of time zone data to update with from the drop down list.</p></li>
<li><p>Click <b>Update</b> to begin updating the selected ICU4J jar files.</p></li>
<a name="cmd"><h4>Running in Command-line Mode</h4></a>
<p>Edit the <b>DirectorySearch.txt</b> file and specify which paths ICUTZU will include and exclude in its search. ICUTZU searches directories recursively.</p>
<li><p><i>all</i> means include all file system roots in the search (for Windows this will include all drives, for Unix-based systems this will include the root directory).</p></li>
<li><p><i>+path</i> means to include <i>path</i> in the search.</p></li>
<li><p><i>-path</i> means to exclude <i>path</i> in the search.</p></li>
<p>Edit the <b>runicutzuenv.X</b> file, where X depends on your system (<b>.sh</b> for Unix-based systems, <b>.bat</b> for Windows, <b>.cmd</b> for Windows NT):</p>
<tr><td valign=top><li><p><b>JAVA_HOME</b>:</td><td>Set this to the path where java is installed on your machine (ie. C:\Program Files\Java\jdk1.5.0 for Windows or /usr/jdk1.5.0 for Unix).</p></li></td></tr>
<tr><td valign=top><li><p><b>NOGUI</b>:</td><td>Set this to <b>true</b> to run in command-line mode. If set to <b>false</b>, ICUTZU will run in <a href="#gui">GUI mode</a> and the DISCOVERONLY option will be ignored.</p></li></td></tr>
<tr><td valign=top><li><p><b>DISCOVERONLY</b>:</td><td>Set this to <b>true</b> the first time ICUTZU is run. When true, ICUTZU will build a list of updatable ICU4J jar files and save it to ICUList.txt. When false, ICUTZU will procede to update the files listed in ICUList.txt.</p></li></td></tr>
<tr><td valign=top><li><p><b>SILENTPATCH</b>:</td><td>Set this to <b>false</b> for normal running, or true to give no output except in the case of an error. This option does not effect the content of the log file.</p></li></td></tr>
<tr><td valign=top><li><p><b>OFFLINE</b>:</td><td>Set this to <b>false</b> for normal running, or true to keep ICUTZU from checking online for the latest time zone data and to use the local copy bundled with ICUTZU instead.</p></li></td></tr>
<li><p>Run <b>runicutzu.X</b> where X depends on your system (as above). This will build a list of updatable ICU4J files and save it to ICUList.txt.</p></li>
<li><p>Edit the <b>runicutzuenv.X</b> file again, and set DISCOVERONLY to <b>false</b>..</p></li>
<li><p>Run <b>runicutzu.X</b> again. This will update the files listed in ICUList.txt.</p></li>
<a name="restore"><h3>Restoring Changes</h3></a>
When updating an icu4j jar file, the original file is copied to a backup location which is reported during runtime in the console output (which can also be found in the log file).
<li><p>The backup location is of the form <i>[icutzu home]<b>/Temp/</b>[prefix]<b>/</b>[prefix]~[unique id]<b>.jar</b></i>, where <i>[prefix]</i> is the filename of the original icu4j jar file without the .jar at the end.</p></li>
<li><p>The txt file in the same directory that shares the same <i>[unique id]</i> specifies the original location.</p></li>
<p>Example: If ICUTZU is running from <b>c:\icutzu</b> and updates <b>c:\icu4j_3-6.jar</b>, the backup will be stored in <b>c:\icutzu\icu4j\icu4j_3-6~</b><i>[unique id]</i><b>.jar</b>.</p>
<p>The file <b>c:\icutzu\icu4j\icu4j_3-6~</b><i>[unique id]</i><b>.txt</b> will contain the original path of icu4j_3-6.jar.</p>