3 %bcond_without tests # make check
5 %define tzdata_ver 2007i
6 %define tzcode_ver 2007h
8 Summary(pl.UTF-8): Dane o strefach czasowych
10 Version: %{tzdata_ver}
12 License: Public Domain (database), BSD/LGPL v2.1+ (code/test suite)
14 Source0: %{name}-base-0.tar.bz2
15 # Source0-md5: 906a4c98cc5240f416524a256b039c42
16 Source1: ftp://elsie.nci.nih.gov/pub/%{name}%{tzdata_ver}.tar.gz
17 # Source1-md5: bfe68c92dbe3726676063bdb14931b8b
18 Source2: ftp://elsie.nci.nih.gov/pub/tzcode%{tzcode_ver}.tar.gz
19 # Source2-md5: e3d9b770e2a74bcddb6aac57f699c961
20 Source3: timezone.init
21 Source4: timezone.sysconfig
22 Patch0: %{name}-test-update.patch
23 URL: http://www.twinsun.com/tz/tz-link.htm
25 BuildRequires: perl-base
26 BuildRequires: rpmbuild(macros) >= 1.228
27 Requires(post,preun): /sbin/chkconfig
28 Requires: rc-scripts >= 0.4.1.4
30 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 This package contains data files with rules for various timezones
36 %description -l pl.UTF-8
37 Ten pakiet zawiera pliki z danymi na temat reguł stref czasowych na
40 %package zoneinfo_right
41 Summary: Non-POSIX (real) time zones
42 Summary(es.UTF-8): Zonas de tiempo reales (no de POSIX)
43 Summary(pl.UTF-8): Nie-POSIX-owe (prawdziwe) strefy czasowe
45 Obsoletes: glibc-zoneinfo_right
47 %description zoneinfo_right
48 You don't want this. Details at:
49 <http://sources.redhat.com/ml/libc-alpha/2000-12/msg00068.html>.
51 %description zoneinfo_right -l es.UTF-8
52 No lo necesita. Encontrará los detalles en:
53 <http://sources.redhat.com/ml/libc-alpha/2000-12/msg00068.html>.
55 %description zoneinfo_right -l pl.UTF-8
56 Nie potrzebujesz tego. Szczegóły pod:
57 <http://sources.redhat.com/ml/libc-alpha/2000-12/msg00068.html>.
61 mkdir %{name}%{version}
62 %{__tar} xzf %{SOURCE1} -C %{name}%{version}
63 mkdir tzcode%{version}
64 %{__tar} xzf %{SOURCE2} -C tzcode%{version}
68 s|@objpfx@|`pwd`/obj/|
69 s|@datadir@|%{_datadir}|
70 s|@install_root@|$RPM_BUILD_ROOT|
71 " Makeconfig.in > Makeconfig
73 grep -v tz-art.htm tzcode%{version}/tz-link.htm > tzcode%{version}/tz-link.html
79 rm -rf $RPM_BUILD_ROOT
80 install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d}
85 : ====================TESTING=========================
88 CFLAGS="%{rpmcflags} %{rpmldflags}"
89 : ====================TESTING END=====================
93 # glibc.spec didn't keep it. so won't here either.
94 rm -rf $RPM_BUILD_ROOT%{_datadir}/zoneinfo/posix
95 # behave more like glibc.spec
96 ln -sf %{_sysconfdir}/localtime $RPM_BUILD_ROOT%{_datadir}/zoneinfo/localtime
97 ln -sf localtime $RPM_BUILD_ROOT%{_datadir}/zoneinfo/posixtime
98 ln -sf localtime $RPM_BUILD_ROOT%{_datadir}/zoneinfo/posixrules
100 > $RPM_BUILD_ROOT/etc/localtime
102 install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/timezone
103 cp -a %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/timezone
106 rm -rf $RPM_BUILD_ROOT
109 /sbin/chkconfig --add timezone
110 %service timezone restart
113 if [ "$1" = "0" ]; then
114 /sbin/chkconfig --del timezone
117 %triggerpostun -- rc-scripts < 0.4.1.4
118 /sbin/chkconfig --add timezone
121 %defattr(644,root,root,755)
122 %doc tzcode%{version}/README tzcode%{version}/Theory tzcode%{version}/tz-link.html
123 %ghost /etc/localtime
124 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/timezone
125 %attr(754,root,root) /etc/rc.d/init.d/timezone
128 %exclude %{_datadir}/zoneinfo/right
130 %files zoneinfo_right
131 %defattr(644,root,root,755)
132 %{_datadir}/zoneinfo/right