tzdata-vl.spec 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415
  1. Summary: Timezone data
  2. Summary(ja): タイムゾーンのデータ
  3. Name: tzdata
  4. Version: 2021a
  5. %define tzdata_version 2021a
  6. %define tzcode_version 2021a
  7. Release: 1%{?_dist_release}
  8. Group: system
  9. Vendor: Project Vine
  10. Distribution: Vine Linux
  11. License: Public Domain
  12. URL: https://www.iana.org/time-zones
  13. # These are official upstream.
  14. Source0: https://data.iana.org/time-zones/releases/tzdata%{tzdata_version}.tar.gz
  15. Source1: https://data.iana.org/time-zones/releases/tzcode%{tzcode_version}.tar.gz
  16. Source2: javazic.tar.gz
  17. Source3: javazic-1.8-37392f2f5d59.tar.xz
  18. Patch002: 0002-Fix-have-snprintf-error.patch
  19. Patch100: javazic-fixup.patch
  20. Patch101: rebase-01.patch
  21. Patch102: rebase-02.patch
  22. Patch103: 7090844.patch
  23. Patch104: 7133138.patch
  24. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  25. BuildArch: noarch
  26. BuildRequires: gawk, glibc, perl
  27. BuildRequires: java-1.8.0-openjdk-devel
  28. BuildRequires: glibc-common >= 2.5.90-7
  29. Conflicts: glibc-common <= 2.3.2-63
  30. %description
  31. This package contains data files with rules for various timezones around
  32. the world.
  33. %description -l ja
  34. このパッケージには世界中のタイムゾーンに関するデータファイルが収録されています.
  35. %package java
  36. Summary: Timezone data for Java
  37. Group: system
  38. %description java
  39. This package contains timezone information for use by Java runtimes.
  40. %prep
  41. %setup -q -c -a 1
  42. %patch002 -p1
  43. # tzdata-2018g introduce 25:00 transition times. This breaks OpenJDK.
  44. # Use rearguard for tzdata-2018g java
  45. mkdir rearguard
  46. make VERSION=%{version} tzdata%{version}-rearguard.tar.gz
  47. mv tzdata%{version}-rearguard.tar.gz rearguard
  48. pushd rearguard
  49. tar zxf tzdata%{version}-rearguard.tar.gz
  50. popd
  51. mkdir javazic
  52. tar zxf %{SOURCE2} -C javazic
  53. pushd javazic
  54. %patch100
  55. %patch101
  56. %patch102
  57. %patch103
  58. %patch104
  59. # Hack alert! sun.tools may be defined and installed in the
  60. # VM. In order to guarantee that we are using IcedTea/OpenJDK
  61. # for creating the zoneinfo files, rebase all the packages
  62. # from "sun." to "rht.". Unfortunately, gcj does not support
  63. # any of the -Xclasspath options, so we must go this route
  64. # to ensure the greatest compatibility.
  65. mv sun rht
  66. find . -type f -name '*.java' -print0 \
  67. | xargs -0 -- sed -i -e 's:sun\.tools\.:rht.tools.:g' \
  68. -e 's:sun\.util\.:rht.util.:g'
  69. popd
  70. tar xf %{SOURCE3}
  71. echo "%{name}%{tzdata_version}" >> VERSION
  72. %build
  73. # Run make to create the tzdata.zi file
  74. rm tzdata.zi
  75. make tzdata.zi
  76. FILES="africa antarctica asia australasia europe northamerica southamerica
  77. etcetera backward factory"
  78. mkdir zoneinfo/{,posix,right}
  79. zic -y ./yearistype -d zoneinfo -L /dev/null -p America/New_York $FILES
  80. zic -y ./yearistype -d zoneinfo/posix -L /dev/null $FILES
  81. zic -y ./yearistype -d zoneinfo/right -L leapseconds $FILES
  82. # tzdata-2018g uses 25:00 which breaks java - use the rearguard files for java
  83. JAVA_FILES="rearguard/africa rearguard/antarctica rearguard/asia \
  84. rearguard/australasia rearguard/europe rearguard/northamerica \
  85. rearguard/southamerica rearguard/pacificnew rearguard/etcetera \
  86. rearguard/backward"
  87. # Java 6/7 tzdata
  88. pushd javazic
  89. javac -source 1.5 -target 1.5 -classpath . `find . -name \*.java`
  90. popd
  91. java -classpath javazic/ rht.tools.javazic.Main -V %{version} \
  92. -d javazi \
  93. $JAVA_FILES javazic/tzdata_jdk/gmt javazic/tzdata_jdk/jdk11_backward
  94. # Java 8 tzdata
  95. pushd javazic-1.8
  96. javac -source 1.7 -target 1.7 -classpath . `find . -name \*.java`
  97. popd
  98. java -classpath javazic-1.8 build.tools.tzdb.TzdbZoneRulesCompiler \
  99. -srcdir . -dstfile tzdb.dat \
  100. -verbose \
  101. $JAVA_FILES javazic-1.8/tzdata_jdk/gmt javazic-1.8/tzdata_jdk/jdk11_backward
  102. %install
  103. rm -fr $RPM_BUILD_ROOT
  104. install -d $RPM_BUILD_ROOT%{_datadir}
  105. cp -prd zoneinfo $RPM_BUILD_ROOT%{_datadir}
  106. install -p -m 644 zone.tab zone1970.tab iso3166.tab leapseconds tzdata.zi $RPM_BUILD_ROOT%{_datadir}/zoneinfo
  107. cp -prd javazi $RPM_BUILD_ROOT%{_datadir}/javazi
  108. mkdir -p $RPM_BUILD_ROOT%{_datadir}/javazi-1.8
  109. install -p -m 644 tzdb.dat $RPM_BUILD_ROOT%{_datadir}/javazi-1.8/
  110. %clean
  111. rm -fr $RPM_BUILD_ROOT
  112. %files
  113. %defattr(-,root,root)
  114. %{_datadir}/zoneinfo
  115. %license LICENSE
  116. %doc README
  117. %doc theory.html
  118. %doc tz-link.html
  119. %doc tz-art.html
  120. %files java
  121. %defattr(-,root,root)
  122. %{_datadir}/javazi
  123. %{_datadir}/javazi-1.8
  124. %changelog
  125. * Thu Feb 25 2021 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2021a-1
  126. - updated to 2021a.
  127. * Sat Mar 21 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2019c-1
  128. - updated to 2019c.
  129. * Sun Jan 06 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2018i-1
  130. - updated to 2018i.
  131. * Mon Jun 26 2017 IWAI, Masaharu <iwaim.sub@gmail.com> 2017b-1
  132. - update to 2017b
  133. * Mon Nov 28 2016 IWAI, Masaharu <iwaim.sub@gmail.com> 2016j-1
  134. - updated to 2016j.
  135. * Thu Jul 14 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2016f-2
  136. - fixed changelog.
  137. - added Vendor and Distribution tag.
  138. * Thu Jul 14 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2016f-1
  139. - updated to 2016f.
  140. * Sun Jun 19 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2016e-1
  141. - updated to 2016e.
  142. - enabled java18 stuff.
  143. * Mon May 9 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2016d-1
  144. - updated to 2016d.
  145. * Mon Aug 17 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2015f-1
  146. - updated to 2015f.
  147. * Wed Jun 17 2015 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2015e-1
  148. - updated to 2015e.
  149. * Sun Jun 24 2012 Daisuke SUZUKI <daisuke@linux.or.jp> 2012c-1
  150. - update to tzdata-2012c, tzcode-2012b
  151. * Sun Apr 17 2011 Shu KONNO <owa@bg.wakwak.com> 2010l-2
  152. - rebuilt with rpm-4.8.1-3
  153. * Sat Sep 04 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2010l-1
  154. - update to tzdata-2010l, tzcode-2010l
  155. - added java subpackage
  156. * Tue Apr 07 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2009d-1
  157. - update to tzdata-2009d, tzcode-2009d
  158. - spec in utf-8
  159. * Sun Apr 06 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2008b-1
  160. - update to tzdata-2008b, tzcode-2008a
  161. * Sun May 06 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 2007d-1vl1
  162. - initial build for VineSeed
  163. * Fri Mar 23 2007 Petr Machata <pmachata@redhat.com> - 2007d-1
  164. - Upstream 2007d
  165. - Mongolia has abolished DST.
  166. - Turkey will use EU rules this year, changing at 01:00 UTC rather
  167. than 01:00 standard time.
  168. - Cuba observed DST starting Sunday.
  169. - Resolute, Nunavut switched from Central to Eastern time last
  170. November.
  171. * Mon Feb 26 2007 Petr Machata <pmachata@redhat.com> - 2007c-1
  172. - Upstream 2007c
  173. - Pulaski County, Indiana, switched back to eastern time.
  174. - Turkey switches at 01:00 standard time, not at 01:00 UTC.
  175. - Upstream 2007b
  176. - Changes to the commentary in "leapseconds".
  177. - Upstream 2007a
  178. - Updates to Bahamas, they will be in sync with 2007 US DST change
  179. - New zone Australia/Eucla
  180. - Africa/Asmera renamed to Africa/Asmara, link created
  181. - Atlantic/Faeroe renamed to Atlantic/Faroe, link created
  182. * Wed Nov 29 2006 Petr Machata <pmachata@redhat.com> - 2006p-1
  183. - Upstream 2006p
  184. - Covers changes from 2006m-2 and 2006m-3
  185. - Latitude/longitude changes for Europe/Jersey and Europe/Podgorica
  186. * Wed Nov 22 2006 Petr Machata <pmachata@redhat.com> - 2006m-3
  187. - Patch for Western Australia DST trial
  188. * Tue Oct 10 2006 Petr Machata <pmachata@redhat.com> - 2006m-2
  189. - Proposed upstream patch (#210058)
  190. - Jordan will switch to winter time on October 27, not September 29
  191. - Brazil's DST this year is the first Sunday in November to the last
  192. Sunday in February. (Thanks to Frederico A. C. Neves.)
  193. - ISO 3166 codes for Serbia and Montenegro, zone Europe/Podgorica
  194. - Commentary and past timestamps changes
  195. * Tue Oct 3 2006 Petr Machata <pmachata@redhat.com> - 2006m-1
  196. - Upstream 2006m:
  197. - Adjustments for Egypt, Palestine, Uruguay
  198. - Better description of `until' field in zic (8) manpage
  199. * Thu Sep 21 2006 Petr Machata <pmachata@redhat.com> - 2006l-1
  200. - Upstream 2006k, 2006l:
  201. - Adjustments for Egypt, Palestine, Cuba, Honduras
  202. - Documentation changes
  203. * Tue Aug 22 2006 Petr Machata <pmachata@redhat.com> - 2006j-1
  204. - Upstream 2006j
  205. - Honduras stopped observing DST on Monday at 00:00
  206. - America/Bermuda will follow the US's lead next year
  207. - America/Moncton will use US-style rules next year
  208. - New Zone America/Blanc-Sablon, for Canadians who observe AST all
  209. year
  210. - New zone: America/Atikokan instead of America/Coral_Harbour
  211. - New zones: Europe/Jersey, Europe/Guernsey, Europe/Isle_of_Man
  212. - Historical changes
  213. - Commentary updates
  214. - Upstream 2006i
  215. - localtime.c fixes
  216. - Upstream 2006h
  217. - zic leapsecond fix
  218. * Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 2006g-1.1
  219. - rebuild
  220. * Thu May 11 2006 Petr Machata <pmachata@redhat.com> - 2006g-1
  221. - Honduras chose to follow Guatemala and will observe DST May/6 to Sep/2
  222. - Nicaragua updates
  223. * Tue May 2 2006 Petr Machata <pmachata@redhat.com> - 2006f-1
  224. - Upstream 2006f
  225. - America/Guatemala observes DST between Apr/30 and Oct/1
  226. - Historical changes for Nicaragua
  227. - Update of America/Indiana/Vincennes in zone table
  228. * Thu Apr 20 2006 Petr Machata <pmachata@redhat.com> - 2006d-1
  229. - Upstream 2006d
  230. - Haiti observes DST
  231. - Sri Lanka change actually took effect Apr/15
  232. - All Canada is now scheduled for 2007 US DST rules
  233. - Some historical fixes
  234. * Thu Apr 6 2006 Petr Machata <pmachata@redhat.com> - 2006c-1
  235. - Upstream 2006c
  236. - Time-related changes:
  237. - dozens of historical and commentary changes
  238. - Iran stopped observing DST
  239. - Sri Lanka switches from UTC+6 to UTC+5:30
  240. - America/Thule and America/Edmonton will adopt new US rules,
  241. starting 2007
  242. - Tunisia is adopting regular DST
  243. - Code:
  244. - asctime.c: Chages in format strings to silent gcc warnings
  245. - removing K&R notation from function signatures
  246. - few fixes across the code
  247. * Thu Mar 16 2006 Petr Machata <pmachata@redhat.com> - 2006b-2
  248. - Patch for Sri Lanka time zone change (#184514)
  249. * Wed Feb 22 2006 Petr Machata <pmachata@redhat.com> 2006b-1
  250. - Upstream 2006b:
  251. - using tz64code version, as 32 is legacy according to tzdata ML
  252. - new manual pages for ctime, strftime, tzset
  253. - some source code reorganizations
  254. - no timezone/dst rule updates
  255. * Thu Feb 02 2006 Petr Machata <pmachata@redhat.com> 2006a-2
  256. - Small changes in tst-timezone.c
  257. * Thu Feb 02 2006 Petr Machata <pmachata@redhat.com> 2006a-1
  258. - Upstream 2006a:
  259. - private.h(scheck): changing char* to char const*
  260. - Rule changes for Palestine, zone changes for Indiana/US, both
  261. changes for Canada.
  262. - Many related doc changes.
  263. - Naming scheme in spec file doesn't use %%{name}, but tzdata.
  264. * Thu Jan 12 2006 Petr Machata <pmachata@redhat.com> 2005r-3
  265. - 2005r-3
  266. - Meta changes. Renaming tzdata.tar.bz2 file to tzdata$ver-base,
  267. so that it won't clash across updates.
  268. * Thu Jan 5 2006 Petr Machata <pmachata@redhat.com> 2005r-2
  269. - 2005r
  270. - Zones EST, MST, HST, EST5EDT, CST6CDT, MST7MDT, PST8PDT moved to
  271. northamerica to guard against old files with obsolete information
  272. being left in the time zone binary directory.
  273. - Changes for countries that are supposed to join 2007 US DST
  274. change. This includes most of Canada, however entries already in
  275. the database (Alberta, British Columbia, Newfoundland, Northwest
  276. Territories, and Yukon) were left alone for the time being.
  277. - Fixes in zdump.c (abbrok): conditions are chained, and the string
  278. is checked for emptiness.
  279. * Sat Dec 17 2005 Jakub Jelinek <jakub@redhat.com> 2005q-2
  280. - 2005q
  281. - changes for Georgia, Azerbaijan, Jordan, Palestine, Cuba, Nicaragua
  282. - SystemV timezone changes
  283. * Wed Nov 2 2005 Jakub Jelinek <jakub@redhat.com> 2005n-2
  284. - 2005n
  285. - changes for Kyrgyzstan and Uruguay
  286. - fix a typo in the Makefile (used TZDATA env var instead of TZDIR during
  287. make check), update tst-timezone.c from glibc CVS (#172102)
  288. * Tue Sep 6 2005 Jakub Jelinek <jakub@redhat.com> 2005m-2
  289. - 2005m
  290. - changes for USA (extending DST by 4 weeks since 2007), Tunisia,
  291. Australia, Kazakhstan
  292. - historical timezone data changes for Japan, Poland, Northern Ireland and
  293. Mali
  294. - timezone name change for East Timor
  295. * Fri Jul 15 2005 Jakub Jelinek <jakub@redhat.com> 2005k-2
  296. - 2005k
  297. - leap seconds update
  298. * Sat Apr 30 2005 Jakub Jelinek <jakub@redhat.com> 2005i-2
  299. - 2005i
  300. - updates for Iran, Haiti and Nicaragua
  301. * Mon Apr 4 2005 Jakub Jelinek <jakub@redhat.com> 2005h-2
  302. - 2005h
  303. - fixes for Kazakhstan
  304. * Thu Mar 17 2005 Jakub Jelinek <jakub@redhat.com> 2005g-2
  305. - 2005g
  306. - fixes for Uruguay
  307. - include README and Theory from tzcode tarball in %{_docdir};
  308. Theory includes a good summary of how the timezone data files
  309. are supposed to be named
  310. * Tue Mar 1 2005 Jakub Jelinek <jakub@redhat.com> 2005f-2
  311. - 2005f
  312. - more updates for Israel, updates for Azerbaijan
  313. * Wed Jan 26 2005 Jakub Jelinek <jakub@redhat.com> 2005c-3
  314. - 2005c
  315. - updates for Israel and Paraguay
  316. * Mon Nov 29 2004 Jakub Jelinek <jakub@redhat.com> 2004g-1
  317. - 2004g (#141107)
  318. - updates for Cuba
  319. * Mon Oct 11 2004 Jakub Jelinek <jakub@redhat.com> 2004e-2
  320. - 2004e (#135194)
  321. - updates for Brazil, Uruguay and Argentina
  322. * Wed Aug 4 2004 Jakub Jelinek <jakub@redhat.com> 2004b-2
  323. - 2004b
  324. * Mon Oct 6 2003 Jakub Jelinek <jakub@redhat.com> 2003d-1
  325. - 2003d
  326. * Thu Sep 25 2003 Jakub Jelinek <jakub@redhat.com> 2003c-1
  327. - 2003c
  328. - updates for Brazil (#104840)
  329. * Mon Jul 28 2003 Jakub Jelinek <jakub@redhat.com> 2003a-2
  330. - rebuilt
  331. * Mon Jul 28 2003 Jakub Jelinek <jakub@redhat.com> 2003a-1
  332. - initial package