diff options
author | Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org> | 2009-04-14 19:37:51 +0000 |
---|---|---|
committer | Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org> | 2009-04-14 19:37:51 +0000 |
commit | 085a97ed3bc9f89031136c03d29e74f32e31d7ea (patch) | |
tree | 26aa9107f61c9e5d8da4033b42d1c12f1fcacf03 /dev-libs/icu | |
parent | Add procps to RDEPEND, fixes bug 174354. (diff) | |
download | historical-085a97ed3bc9f89031136c03d29e74f32e31d7ea.tar.gz historical-085a97ed3bc9f89031136c03d29e74f32e31d7ea.tar.bz2 historical-085a97ed3bc9f89031136c03d29e74f32e31d7ea.zip |
Fix TestDisplayNamesMeta test (bug #265352).
Package-Manager: portage-13343-svn/cvs/Linux x86_64
Diffstat (limited to 'dev-libs/icu')
-rw-r--r-- | dev-libs/icu/ChangeLog | 6 | ||||
-rw-r--r-- | dev-libs/icu/Manifest | 5 | ||||
-rw-r--r-- | dev-libs/icu/files/icu-4.0.1-TestDisplayNamesMeta.patch | 177 | ||||
-rw-r--r-- | dev-libs/icu/icu-4.0.1.ebuild | 3 |
4 files changed, 187 insertions, 4 deletions
diff --git a/dev-libs/icu/ChangeLog b/dev-libs/icu/ChangeLog index 79da5e6b9961..2f24bd867677 100644 --- a/dev-libs/icu/ChangeLog +++ b/dev-libs/icu/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for dev-libs/icu # Copyright 2002-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/ChangeLog,v 1.78 2009/04/14 13:48:34 arfrever Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/ChangeLog,v 1.79 2009/04/14 19:37:51 arfrever Exp $ + + 14 Apr 2009; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org> + +files/icu-4.0.1-TestDisplayNamesMeta.patch, icu-4.0.1.ebuild: + Fix TestDisplayNamesMeta test (bug #265352). 14 Apr 2009; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org> +files/icu-4.0.1-fix_parallel_building.patch, icu-4.0.1.ebuild: diff --git a/dev-libs/icu/Manifest b/dev-libs/icu/Manifest index a0c1f130f7a1..098c3c0481c6 100644 --- a/dev-libs/icu/Manifest +++ b/dev-libs/icu/Manifest @@ -1,6 +1,7 @@ AUX icu-3.6-regexp-CVE-2007-4770+4771.diff 10813 RMD160 e28e0704389087b49263b93781cfaf8564ba7bd0 SHA1 42da32eb2aaa9ffed8b67d88268d8b144186cbb6 SHA256 ae908b683114b4874a84abdee963bcf6ff4dd65f9ba045b1843dffa1df7ac02f AUX icu-3.8-regexp-CVE-2007-4770+4771.diff 10839 RMD160 efeef3970293df08a430e5c797d0b9c3a8198dfd SHA1 aceeabc01355360866cb17811f4ad7e709498b80 SHA256 ec22413f8544c399241b9a7ca6d9c92c5414701ec1d7f536fdb8e6fe35717916 AUX icu-3.8-setBreakType-public.diff 900 RMD160 ba2d421389829d25b04ae6debc8ad16f2f183ddf SHA1 692f373ea8e52189b7dfa60dd34805411488ef2b SHA256 b3f2b1651ae47ef9c0ba72712dc88d377ac92e6d3f1f621316aead217f4ee325 +AUX icu-4.0.1-TestDisplayNamesMeta.patch 8259 RMD160 4eb64876eee0ff21577f8330326ba96010545cc1 SHA1 d8fe22be87fbb99f8c1a0bbb9d94bc2d93ca083a SHA256 cfcedc486f4c530e43b5fffacf4068f76d026ab73dd4aa1dff253fc87c2e462c AUX icu-4.0.1-fix_parallel_building.patch 145 RMD160 d7e74631383b01a7cd9d18f9fda2949e1b3ec198 SHA1 5edcb46b7730b11aeaf5ed2e8e968e588eb1d492 SHA256 244bee4fcabe5c1bcf95af2d9a01d87b2de27407e662f2c1663c5ce15ac8a561 DIST icu-3_8-userguide.zip 2611858 RMD160 8fa028c73aedb9ef5fe2ff895469088ee0a4b5af SHA1 de16e72a8f53da466223ea34fb7385fe52b06736 SHA256 c61a3c2c923e08b5e0ee544b5e417058e4566878f8144a745924c5693ca160bb DIST icu-4_0-userguide.zip 2201832 RMD160 efbde385d89be4f91f4945c963d3abc118121f50 SHA1 a4c7bbe4ce0b99bf907b598620aa58daf51d6883 SHA256 db9accfdfdb6536881513d8d0c09ff53cee0340804f0f06ed4fb303cceed1092 @@ -14,6 +15,6 @@ EBUILD icu-3.6-r2.ebuild 951 RMD160 9bbf921a1e5cdf0c14d3cbc6319f15c99c9fd255 SHA EBUILD icu-3.6.ebuild 785 RMD160 eb6909d0df984843c91f207457a6ff278feb4ca3 SHA1 64f830d48b4dfb5c483092fef9e461dd6921f07d SHA256 b7d25aa35769dcbd7efe3fa0c56aca95563ba357aaa9930ed353f5811a843790 EBUILD icu-3.8.1-r1.ebuild 2198 RMD160 7191b20982e0739652806b340b05c8aa26b08c04 SHA1 0a2fd2fd31b7c76c2604dc66ca6e9eb0e9170969 SHA256 dd6eb86d0420cd217fe40e26b9c5bf9eec5464430112747d97ba596f5d783285 EBUILD icu-3.8.1.ebuild 2127 RMD160 36529afc1e92db143f9242644673ea427899b5f4 SHA1 35f5dc7a078af711c4aa34cea1dd4f3e2465a887 SHA256 047b24905b0dd4bccf88b7948c702aeee4dd868558fb40149baaed817befe1b1 -EBUILD icu-4.0.1.ebuild 2024 RMD160 cb97d526edbf75f403c26b86007b1208cec20b12 SHA1 4f9b8baed75deabf159c719e6c3b8513605d7d8e SHA256 2b0bdec33dcc146860129b52b150b180c9de37f3bb8e8e17a11fd3b037491de0 -MISC ChangeLog 9295 RMD160 e229efa53d6416ed056da1d90de4ca05d5339bcd SHA1 11eecc66a58dc8f5b1865a1c759da36353bb571b SHA256 a8f25cd2d0f30ecfaa6711bfadf09d1f50af9fe8580ae05b95f5a16420ca5253 +EBUILD icu-4.0.1.ebuild 2078 RMD160 42123e126e0bb73891a9155e298316cc83415659 SHA1 e96b6de99ebd832d531fa759f887ae03da8c5f24 SHA256 129012f93efc9fb23c9f58a482c7b72ba097ccf20315b1b9a12c857119631628 +MISC ChangeLog 9481 RMD160 ffbb1b112b4e9219991c087097dce3c5f7819cbd SHA1 56145a4a85db1abf81fda7246c89b35b01989f59 SHA256 5be0bee65b57e2c86480045d91fa5d426a251c86db181d34da66efeae21a6813 MISC metadata.xml 274 RMD160 c5ce174bf40a37d632d003bab5e2c5b97777a1c6 SHA1 ccf8f018b8d3a49a1557b5f77e29802cbbc6140d SHA256 b2c70fe9d0595a367c5d41793662a02d301f77b09b6dc70f5b675c2725419a6a diff --git a/dev-libs/icu/files/icu-4.0.1-TestDisplayNamesMeta.patch b/dev-libs/icu/files/icu-4.0.1-TestDisplayNamesMeta.patch new file mode 100644 index 000000000000..be1f7ec59f25 --- /dev/null +++ b/dev-libs/icu/files/icu-4.0.1-TestDisplayNamesMeta.patch @@ -0,0 +1,177 @@ +https://bugs.icu-project.org/trac/ticket/6814 +https://bugs.icu-project.org/trac/changeset/25681 + +--- i18n/olsontz.cpp ++++ i18n/olsontz.cpp +@@ -1,6 +1,6 @@ + /* + ********************************************************************** +-* Copyright (c) 2003-2008, International Business Machines ++* Copyright (c) 2003-2009, International Business Machines + * Corporation and others. All Rights Reserved. + ********************************************************************** + * Author: Alan Liu +@@ -526,8 +526,8 @@ + if (transitionTimes[i] >= limit) { + break; + } +- if (transitionTimes[i] >= start && +- dstOffset(typeData[i]) != 0) { ++ if ((transitionTimes[i] >= start && dstOffset(typeData[i]) != 0) ++ || (transitionTimes[i] > start && i > 0 && dstOffset(typeData[i - 1]) != 0)) { + return TRUE; + } + } +--- i18n/timezone.cpp ++++ i18n/timezone.cpp +@@ -1,6 +1,6 @@ + /* + ******************************************************************************* +-* Copyright (C) 1997-2008, International Business Machines Corporation and * ++* Copyright (C) 1997-2009, International Business Machines Corporation and * + * others. All Rights Reserved. * + ******************************************************************************* + * +@@ -1240,6 +1240,8 @@ + } + } else { + // The display name for standard time was requested, but currently in DST ++ // or display name for daylight saving time was requested, but this zone no longer ++ // observes DST. + tz = new SimpleTimeZone(rawOffset, tempID); + if (U_FAILURE(status) || tz == NULL) { + if (U_SUCCESS(status)) { +--- test/intltest/tztest.cpp ++++ test/intltest/tztest.cpp +@@ -34,6 +34,11 @@ + // class TimeZoneTest + // ***************************************************************************** + ++// TODO: We should probably read following data at runtime, so we can update ++// the these values every release with necessary data changes. ++const int32_t TimeZoneTest::REFERENCE_YEAR = 2009; ++const char * TimeZoneTest::REFERENCE_DATA_VERSION = "2009d"; ++ + void TimeZoneTest::runIndexedTest( int32_t index, UBool exec, const char* &name, char* /*par*/ ) + { + if (exec) logln("TestSuite TestTimeZone"); +@@ -579,18 +584,13 @@ + */ + void TimeZoneTest::TestShortZoneIDs() + { +- // TODO: This test case is tzdata sensitive. +- // We should actually put the data version in this test code +- // at build time. For now, we just hardcode the version string +- // and display warning instead of error if non-reference tzdata +- // version is used. +- const char *REFERENCE_DATA_VERSION = "2008i"; +- + UErrorCode status = U_ZERO_ERROR; ++ ++ // This test case is tzdata version sensitive. + UBool isNonReferenceTzdataVersion = FALSE; + const char *tzdataVer = TimeZone::getTZDataVersion(status); + if (failure(status, "getTZDataVersion")) return; +- if (uprv_strcmp(tzdataVer, REFERENCE_DATA_VERSION) != 0) { ++ if (uprv_strcmp(tzdataVer, TimeZoneTest::REFERENCE_DATA_VERSION) != 0) { + // Note: We want to display a warning message here if + // REFERENCE_DATA_VERSION is out of date - so we + // do not forget to update the value before GA. +@@ -603,11 +603,11 @@ + // Note: useDaylightTime returns true if DST is observed + // in the time zone in the current calendar year. The test + // data is valid for the date after the reference year below. +- // If system clock is before the year, some test cases may fail. +- const int32_t REFERENCE_YEAR = 2009; ++ // If system clock is before the year, some test cases may ++ // fail. + GregorianCalendar cal(*TimeZone::getGMT(), status); + if (failure(status, "GregorianCalendar")) return; +- cal.set(REFERENCE_YEAR, UCAL_JANUARY, 2); // day 2 in GMT ++ cal.set(TimeZoneTest::REFERENCE_YEAR, UCAL_JANUARY, 2); // day 2 in GMT + + UBool isDateBeforeReferenceYear = ucal_getNow() < cal.getTime(status); + if (failure(status, "Calendar::getTime")) return; +@@ -1898,6 +1898,15 @@ + }; + + void TimeZoneTest::TestDisplayNamesMeta() { ++ UErrorCode status = U_ZERO_ERROR; ++ GregorianCalendar cal(*TimeZone::getGMT(), status); ++ if (failure(status, "GregorianCalendar")) return; ++ ++ UBool isReferenceYear = TRUE; ++ if (cal.get(UCAL_YEAR, status) != TimeZoneTest::REFERENCE_YEAR) { ++ isReferenceYear = FALSE; ++ } ++ + UBool sawAnError = FALSE; + for (int testNum = 0; zoneDisplayTestData[testNum].zoneName != NULL; testNum++) { + Locale locale = Locale::createFromName(zoneDisplayTestData[testNum].localeName); +@@ -1908,20 +1917,33 @@ + locale, + displayName); + if (displayName != zoneDisplayTestData[testNum].expectedDisplayName) { +- sawAnError = TRUE; + char name[100]; + UErrorCode status = U_ZERO_ERROR; + displayName.extract(name, 100, NULL, status); +- errln("Incorrect time zone display name. zone = \"%s\",\n" +- " locale = \"%s\", style = %s, Summertime = %d\n" +- " Expected \"%s\", " +- " Got \"%s\"\n", zoneDisplayTestData[testNum].zoneName, +- zoneDisplayTestData[testNum].localeName, +- zoneDisplayTestData[testNum].style==TimeZone::SHORT ? +- "SHORT" : "LONG", +- zoneDisplayTestData[testNum].summerTime, +- zoneDisplayTestData[testNum].expectedDisplayName, +- name); ++ if (isReferenceYear) { ++ sawAnError = TRUE; ++ errln("Incorrect time zone display name. zone = \"%s\",\n" ++ " locale = \"%s\", style = %s, Summertime = %d\n" ++ " Expected \"%s\", " ++ " Got \"%s\"\n", zoneDisplayTestData[testNum].zoneName, ++ zoneDisplayTestData[testNum].localeName, ++ zoneDisplayTestData[testNum].style==TimeZone::SHORT ? ++ "SHORT" : "LONG", ++ zoneDisplayTestData[testNum].summerTime, ++ zoneDisplayTestData[testNum].expectedDisplayName, ++ name); ++ } else { ++ logln("Incorrect time zone display name. zone = \"%s\",\n" ++ " locale = \"%s\", style = %s, Summertime = %d\n" ++ " Expected \"%s\", " ++ " Got \"%s\"\n", zoneDisplayTestData[testNum].zoneName, ++ zoneDisplayTestData[testNum].localeName, ++ zoneDisplayTestData[testNum].style==TimeZone::SHORT ? ++ "SHORT" : "LONG", ++ zoneDisplayTestData[testNum].summerTime, ++ zoneDisplayTestData[testNum].expectedDisplayName, ++ name); ++ } + } + delete zone; + } +--- test/intltest/tztest.h ++++ test/intltest/tztest.h +@@ -1,6 +1,6 @@ + + /******************************************************************** +- * Copyright (c) 1997-2008, International Business Machines ++ * Copyright (c) 1997-2009, International Business Machines + * Corporation and others. All Rights Reserved. + ********************************************************************/ + +@@ -98,6 +98,11 @@ + // internal functions + static UnicodeString& formatOffset(int32_t offset, UnicodeString& rv); + static UnicodeString& formatTZID(int32_t offset, UnicodeString& rv); ++ ++ // Some test case data is current date/tzdata version sensitive and producing errors ++ // when year/rule are changed. ++ static const int32_t REFERENCE_YEAR; ++ static const char *REFERENCE_DATA_VERSION; + }; + + #endif /* #if !UCONFIG_NO_FORMATTING */ diff --git a/dev-libs/icu/icu-4.0.1.ebuild b/dev-libs/icu/icu-4.0.1.ebuild index ec215ebb8688..1d7cfd98b2e9 100644 --- a/dev-libs/icu/icu-4.0.1.ebuild +++ b/dev-libs/icu/icu-4.0.1.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/icu-4.0.1.ebuild,v 1.2 2009/04/14 13:48:34 arfrever Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/icu-4.0.1.ebuild,v 1.3 2009/04/14 19:37:51 arfrever Exp $ EAPI="2" @@ -55,6 +55,7 @@ src_prepare() { done epatch "${FILESDIR}/${P}-fix_parallel_building.patch" + epatch "${FILESDIR}/${P}-TestDisplayNamesMeta.patch" } src_configure() { |