gecko/intl/icu/source/data/build.xml
Jeff Walden dd00554d2b Bug 924839 - Update our embedded ICU to 52.1, plus a very few local patches. r=lots of people, see subsequent lines in this commit message for the original subcomponents (merged together for landing), and the original bug for the original patch divisions
Bug 924839 - Remove a patch already part of ICU 52.1.  See http://bugs.icu-project.org/trac/ticket/10283 but also note the relevant code was removed completely upstream.  r=glandium
* * *
Bug 924839 - Remove another patch already part of ICU 52.1.  See http://bugs.icu-project.org/trac/ticket/10290 for that.  r=gaston
* * *
Bug 924839 - Remove another patch already in ICU 52.1.  See http://bugs.icu-project.org/trac/ticket/10045 for more.  r=Norbert
* * *
Bug 924839 - Remove another patch already applied upstream.  See http://bugs.icu-project.org/trac/changeset/32937 for more.  r=gaston
* * *
Bug 924839 - Update the ICU update script to update to 52.1, *without* applying any of our local patches.  r=glandium
* * *
Bug 924839 - Make the ICU update script only do updating within intl/icu/source and nowhere else.  r=glandium
* * *
Bug 924839 - Implement the changes that would be made by |cd intl/; ./update-icu.sh http://source.icu-project.org/repos/icu/icu/tags/release-52-1/;|, run with the prior changesets' changes made (thus not applying any of our local patches).  These changes don't actually work without subsequent adjustments, but this provides a codebase upon which those adjustments can be made, for the purpose of generating local patches to be kept in intl/icu-patches/.  rs=the-usual-suspects
* * *
Bug 924839 - Update the bug 899722 local patch to make runConfigureICU not override CC/CXX on BSD systems.  r=gaston
* * *
Bug 924839 - Update the bug 724533 patch that makes ICU builds with MozillaBuild on Windows.  r=glandium
* * *
Bug 924839 - Import an upstream patch fixing the genrb tool to properly handle the -R (--omitCollationRules) option.  See http://bugs.icu-project.org/trac/ticket/10043 for the original bug report and a link to the ultimate upstream landing.  r=Norbert
* * *
Bug 924839 - Import the upstream fix for http://bugs.icu-project.org/trac/ticket/10486 so that ICU with -DU_USING_ICU_NAMESPACE=0 will compile on Windows.  r=Norbert
* * *
Bug 924839 - Adjust the update script to update ICU, then to apply all local patches (rather than skipping the second step).  Thus if the update script is properly run, now, the final result should be no changes at all to the tree.  NOT REVIEWED YET
* * *
Bug 924839 - Update jstests that depend on CLDR locale data to match CLDR 24.  r=Norbert

--HG--
extra : rebase_source : e993b6e4a507f92d1b1a24949185d00d1f6201f2
2013-11-12 16:23:48 -08:00

446 lines
22 KiB
XML

<!DOCTYPE project [
<!ENTITY icu-config SYSTEM "./icu-config.xml">
<!ENTITY icu-locale-deprecates SYSTEM "./icu-locale-deprecates.xml">
]>
<!--
/*
*******************************************************************************
* Copyright (C) 2005-2013, International Business Machines Corporation and *
* others. All Rights Reserved. *
*******************************************************************************
*/
-->
<project name="icu-build" default="all" basedir=".">
<target name="init">
<tstamp/>
<!-- Load environment variables -->
<property environment="env"/>
<!-- Ant won't set properties that have already been set, so environment variables that have been set before won't be clobbered. -->
<property name="env.ICU4C_DIR" location="../.."/>
<condition property="is.cldr.dir.set" >
<isset property="env.CLDR_DIR" />
</condition >
<fail unless="is.cldr.dir.set" message="Please set the CLDR_DIR environment variable to the top level ICU source dir (containing 'common')."/>
<available property="cldrtools.dir" value="${env.CLDR_DIR}/cldr-tools" file="${env.CLDR_DIR}/cldr-tools" type="dir"/>
<available property="cldrtools.dir" value="${env.CLDR_DIR}/tools/java" file="${env.CLDR_DIR}/tools/java" type="dir"/>
<fail unless="cldrtools.dir" message="Please make sure that the CLDR tools directory is checked out into CLDR_DIR"/>
<available property="env.CLDR_CLASSES" value="${cldrtools.dir}/classes" file="${cldrtools.dir}/classes" type="dir"/>
<available property="cldrtools.jar" value="${cldrtools.dir}/cldr.jar" file="${cldrtools.dir}/cldr.jar" type="file"/>
<condition property="is.cldr.classes.set">
<or>
<isset property="env.CLDR_CLASSES" />
<isset property="cldrtools.jar" />
</or>
</condition>
<fail unless="is.cldr.classes.set" message="CLDR classes not found in ${cldrtools.dir}. Please either set the CLDR_CLASSES environment variable or build cldr.jar."/>
<echo message="java home: ${java.home}"/>
<echo message="java version: ${java.version}"/>
<echo message="ant java version: ${ant.java.version}"/>
<echo message="${ant.version}"/>
</target>
<target name="setup">
<taskdef name="cldr-build" classname="org.unicode.cldr.ant.CLDRBuild">
<classpath>
<pathelement path="${java.class.path}/"/>
<pathelement path="${env.CLDR_CLASSES}"/>
<pathelement location="${cldrtools.jar}"/>
<fileset dir="${cldrtools.dir}/libs" includes="*.jar"/>
</classpath>
</taskdef>
</target>
<!-- target for generating ICU data -->
<target name="all" depends="locales, collation, rbnf, supplementalData, metadata, metaZones, windowsZones, likelySubtags, plurals, numberingSystems, translit, brkitr, keyTypeData, genderList, postalCodeData, dayPeriods" />
<!-- parallel target -->
<target name="pall" depends="init">
<parallel threadsPerProcessor ="1">
<sequential>
<ant target='locales' />
</sequential>
<sequential>
<ant target='collation'>
</ant>
</sequential>
<sequential>
<ant target='rbnf'>
</ant>
</sequential>
<ant target='supplementalData'>
</ant>
<sequential>
<ant target='brkitr'>
</ant>
</sequential>
<sequential>
<ant target='translit'>
</ant>
<!--<ant target='trnsfiles'></ant> Not ANT-built - see
note below. -->
</sequential>
</parallel>
</target>
<target name="locales" depends="init,setup" description="builds locale files in ICU text format">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" srcFile=".*xml" destFile=".*txt">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="--sourcedir" value="${env.CLDR_DIR}/common/main" />
<arg name="--destdir" value="${env.ICU4C_DIR}/source/data/locales"/>
<arg name="--specialsdir" value="${env.ICU4C_DIR}/source/data/xml/main"/>
<arg name="--supplementaldir" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="--type" value="locales"/>
<arg name="--makefile" value="resfiles.mk"/>
</args>
<remapper>
<remap sourcePath="/Keys" targetDir="lang" />
<remap sourcePath="/Languages" targetDir="lang" />
<remap sourcePath="/LanguagesShort" targetDir="lang" />
<remap sourcePath="/Scripts" targetDir="lang" />
<remap sourcePath="/Scripts%stand-alone" targetDir="lang" />
<remap sourcePath="/Types" targetDir="lang" />
<remap sourcePath="/Variants" targetDir="lang" />
<remap sourcePath="/codePatterns" targetDir="lang" />
<remap sourcePath="/localeDisplayPattern" targetDir="lang" />
<remap sourcePath="/Countries" targetDir="region" />
<remap sourcePath="/CountriesShort" targetDir="region" />
<remap sourcePath="/Currencies" targetDir="curr" />
<remap sourcePath="/CurrencyPlurals" targetDir="curr" />
<remap sourcePath="/CurrencyUnitPatterns" targetDir="curr" />
<remap sourcePath="/currencySpacing" targetDir="curr" />
<remap sourcePath="/zoneStrings" targetDir="zone" />
</remapper>
<!-- http://ant.apache.org/faq.html#xml-entity-include -->
&icu-config;
&icu-locale-deprecates;
</run>
</cldr-build>
</target>
<target name="collation" depends="init,setup" description="builds collation files in ICU text format">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" srcFile=".*xml" destFile=".*txt">
<run>
<args>
<arg name="--sourcedir" value="${env.CLDR_DIR}/common/collation" />
<arg name="--destdir" value="${env.ICU4C_DIR}/source/data/coll"/>
<arg name="--specialsdir" value="${env.ICU4C_DIR}/source/data/xml/collation"/>
<arg name="--type" value="collation"/>
<arg name="--makefile" value="colfiles.mk"/>
</args>
<!-- http://ant.apache.org/faq.html#xml-entity-include -->
&icu-config;
<deprecates>
<alias from="de__PHONEBOOK" to="de" rbpath="/collations/default" value="phonebook"/>
<alias from="es__TRADITIONAL" to="es" rbpath="/collations/default" value="traditional"/>
<alias from="in" to="id" />
<alias from="in_ID" to="id_ID" />
<alias from="iw" to="he" />
<alias from="iw_IL" to="he_IL" />
<alias from="mo" to="ro_MD" />
<alias from="no" to="nb" />
<alias from="no_NO" to="nb_NO" />
<alias from="pa_IN" to="pa_Guru_IN" />
<alias from="sh" to="sr_Latn" />
<alias from="sh_BA" to="sr_Latn_BA" />
<alias from="sh_CS" to="sr_Latn_RS" />
<alias from="sh_YU" to="sr_Latn_RS" />
<alias from="sr_BA" to="sr_Cyrl_BA" />
<alias from="sr_ME" to="sr_Cyrl_ME" />
<alias from="sr_RS" to="sr_Cyrl_RS" />
<alias from="zh_CN" to="zh_Hans_CN" />
<alias from="zh_SG" to="zh_Hans_SG" />
<alias from="zh_HK" to="zh_Hant_HK" />
<alias from="zh_MO" to="zh_Hant_MO" />
<alias from="zh_TW" to="zh_Hant_TW" />
<emptyLocale locale="de_" />
<emptyLocale locale="es_" />
</deprecates>
</run>
</cldr-build>
</target>
<target name="rbnf" depends="init,setup" description="builds rbnf files in ICU text format">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" srcFile=".*xml" destFile=".*txt">
<run>
<args>
<arg name="--sourcedir" value="${env.CLDR_DIR}/common/rbnf" />
<arg name="--destdir" value="${env.ICU4C_DIR}/source/data/rbnf"/>
<arg name="--specialsdir" value="${env.ICU4C_DIR}/source/data/xml/rbnf"/>
<arg name="--type" value="rbnf" />
<arg name="--makefile" value="rbnffiles.mk"/>
</args>
<!-- http://ant.apache.org/faq.html#xml-entity-include -->
&icu-config;
</run>
</cldr-build>
</target>
<target name="supplementalData" depends="init,setup" description="builds supplementalData.txt from supplementalData.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="supplementalData.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="supplementalData"/>
</args>
<remapper>
<remap sourcePath="/CurrencyMap" targetDir="curr" />
<remap sourcePath="/CurrencyMeta" targetDir="curr" />
</remapper>
</run>
</cldr-build>
</target>
<target name="metadata" depends="init,setup" description="builds metadata.txt from supplementalMetadata.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="metadata.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="metadata"/>
</args>
</run>
</cldr-build>
</target>
<target name="metaZones" depends="init,setup" description="builds metaZones.txt from metaZones.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="metaZones.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="metaZones"/>
</args>
</run>
</cldr-build>
</target>
<target name="windowsZones" depends="init,setup" description="builds windowsZones.txt from windowsZones.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="windowsZones.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="windowsZones"/>
</args>
</run>
</cldr-build>
</target>
<target name="likelySubtags" depends="init,setup" description="builds likelySubtags.txt from likelySubtags.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="likelySubtags.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="likelySubtags"/>
</args>
</run>
</cldr-build>
</target>
<target name="plurals" depends="init,setup" description="builds plurals.txt from plurals.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="plurals.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="plurals"/>
</args>
</run>
</cldr-build>
</target>
<target name="numberingSystems" depends="init,setup" description="builds numberingSystems.txt from numberingSystems.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="numberingSystems.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="numberingSystems"/>
</args>
</run>
</cldr-build>
</target>
<target name="genderList" depends="init,setup" description="builds genderList.txt from genderList.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="genderList.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="genderList"/>
</args>
</run>
</cldr-build>
</target>
<target name="postalCodeData" depends="init,setup" description="builds postalCodeData.txt from postalCodeData.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="postalCodeData.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="postalCodeData"/>
</args>
</run>
</cldr-build>
</target>
<target name="dayPeriods" depends="init,setup" description="builds dayPeriods.txt from dayPeriods.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" destFile="dayPeriods.txt" noArgs="true">
<!-- launch the tool and generate the data after reading the config file -->
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/supplemental" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="dayPeriods"/>
</args>
</run>
</cldr-build>
</target>
<target name="brkitr" depends="init,setup" description="builds break iterator files in ICU text format">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" srcFile=".*xml" destFile=".*txt">
<run>
<args>
<arg name="--sourcedir" value="${env.ICU4C_DIR}/source/data/xml/brkitr"/>
<arg name="--destdir" value="${env.ICU4C_DIR}/source/data/brkitr"/>
<arg name="--type" value="brkitr" />
<arg name="--makefile" value="brkfiles.mk"/>
</args>
<!-- The entity include is not required for this target -->
<!-- http://ant.apache.org/faq.html#xml-entity-include
&icu-config;
-->
</run>
</cldr-build>
</target>
<target name="keyTypeData" depends="init,setup" description="builds keyTypeData.txt and timezoneTypes.txt from bcp47/*.xml">
<cldr-build toolName="org.unicode.cldr.icu.NewLdml2IcuConverter" noArgs="true">
<run>
<args>
<arg name="-s" value="${env.CLDR_DIR}/common/bcp47" />
<arg name="-d" value="${env.ICU4C_DIR}/source/data/misc"/>
<arg name="-t" value="keyTypeData"/>
</args>
</run>
</cldr-build>
</target>
<target name="translit" depends="init,setup" description="builds collation files in ICU text format">
<cldr-build toolName="org.unicode.cldr.icu.ConvertTransforms" srcFile=".*xml" destFile=".*txt">
<run>
<args>
<arg name="-m" value="((?!.*(Canadian|Ethiopic).*).*)" />
<arg name="--sourcedir" value="${env.CLDR_DIR}/common/transforms" />
<arg name="--destdir" value="${env.ICU4C_DIR}/source/data/translit"/>
<arg name="--commentSkip"/>
</args>
<!-- http://ant.apache.org/faq.html#xml-entity-include -->
</run>
</cldr-build>
</target>
<!-- we don't generate en.txt or el.txt - so don't change trnsfiles.mk for now. -->
<!--
<target name="trnsfiles" depends="init, setup" description="builds trnsfiles.mk">
<cldr-build toolName="org.unicode.cldr.icu.ConvertTransforms" srcFile=".*xml" destFile="trnsfiles.mk" noArgs="true">
<run>
<args> [ double hyphen not allowed in comments - transpose -" to fix below ]
<arg name=-"-sourcedir" value="${env.CLDR_DIR}/common/transforms" />
<arg name=-"-destdir" value="${env.ICU4C_DIR}/source/data/translit"/>
<arg name=-"-commentSkip"/>
<arg name=-"-writeIndex"/>
</args>
</run>
</cldr-build>
</target> -->
<target name="clean" depends="init, setup" description="deletes all txt files and mk files from coll and locales directories">
<delete>
<fileset id="locales" dir="${env.ICU4C_DIR}/source/data/locales">
<include name="*.txt" />
</fileset>
<fileset id="resfiles" dir="${env.ICU4C_DIR}/source/data/locales">
<include name="resfiles.mk" />
</fileset>
<fileset id="locales_split" dir="${env.ICU4C_DIR}/source/data">
<include name="curr/*.txt" />
<include name="curr/resfiles.mk" />
<include name="lang/*.txt" />
<include name="lang/resfiles.mk" />
<include name="region/*.txt" />
<include name="region/resfiles.mk" />
<include name="zone/*.txt" />
<include name="zone/resfiles.mk" />
</fileset>
<fileset id="collation" dir="${env.ICU4C_DIR}/source/data/coll">
<include name="*.txt" />
</fileset>
<fileset id="colfiles" dir="${env.ICU4C_DIR}/source/data/coll">
<include name="colfiles.mk" />
</fileset>
<fileset id="translit" dir="${env.ICU4C_DIR}/source/data/translit">
<include name="*_*.txt" />
<include name="root.txt" />
</fileset>
<fileset id="brkitr" dir="${env.ICU4C_DIR}/source/data/brkitr">
<!-- brkitr directory contains bunch of txt files that are not produced by LDML2ICUConverter.
So can't clean up everything. This needs to be updated when new files are added to xml/brkitr directory -->
<include name="root.txt" />
<include name="el.txt" />
<include name="en.txt" />
<include name="en_US.txt" />
<include name="en_US_POSIX.txt" />
<include name="fi.txt" />
<include name="ja.txt" />
</fileset>
<fileset id="brkfiles" dir="${env.ICU4C_DIR}/source/data/brkitr">
<include name="brkfiles.mk" />
</fileset>
<fileset id="supplementalData" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="supplementalData.txt" />
</fileset>
<fileset id="rbnf" dir="${env.ICU4C_DIR}/source/data/rbnf">
<include name="*.txt" />
</fileset>
<fileset id="rbnffiles" dir="${env.ICU4C_DIR}/source/data/rbnf">
<include name="rbnffiles.mk" />
</fileset>
<fileset id="metadata" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="metadata.txt" />
</fileset>
<fileset id="metaZones" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="metaZones.txt" />
</fileset>
<fileset id="windowsZones" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="windowsZones.txt" />
</fileset>
<fileset id="likelySubtags" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="likelySubtags.txt" />
</fileset>
<fileset id="plurals" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="plurals.txt" />
</fileset>
<fileset id="numberingSystems" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="numberingSystems.txt" />
</fileset>
<fileset id="keyTypeData" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="keyTypeData.txt" />
<include name="timezoneTypes.txt" />
</fileset>
<fileset id="genderList" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="genderList.txt" />
</fileset>
<fileset id="postalCodeData" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="postalCodeData.txt" />
</fileset>
<fileset id="dayPeriods" dir="${env.ICU4C_DIR}/source/data/misc">
<include name="dayPeriods.txt" />
</fileset>
</delete>
</target>
</project>