diff --git a/base/tzdata/destdir.patch b/base/tzdata/destdir.patch new file mode 100644 index 000000000..4230d64ad --- /dev/null +++ b/base/tzdata/destdir.patch @@ -0,0 +1,117 @@ +# --- SDE-COPYRIGHT-NOTE-BEGIN --- +# This copyright note is auto-generated by ./scripts/Create-CopyPatch. +# +# Filename: package/.../tzdata/destdir.patch +# Copyright (C) 2008 The OpenSDE Project +# +# More information can be found in the files COPYING and README. +# +# This patch file is dual-licensed. It is available under the license the +# patched project is licensed under, as long as it is an OpenSource license +# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms +# of the GNU General Public License as published by the Free Software +# Foundation; either version 2 of the License, or (at your option) any later +# version. +# --- SDE-COPYRIGHT-NOTE-END --- + +--- ./Makefile.orig 2007-12-27 17:14:21.000000000 +0000 ++++ ./Makefile 2008-01-31 03:19:05.000000000 +0000 +@@ -242,6 +242,7 @@ + cc= cc + CC= $(cc) -DTZDIR=\"$(TZDIR)\" + ++RANLIB= ranlib + TZCSRCS= zic.c localtime.c asctime.c scheck.c ialloc.c + TZCOBJS= zic.o localtime.o asctime.o scheck.o ialloc.o + TZDSRCS= zdump.c localtime.c ialloc.c +@@ -282,29 +283,30 @@ + + install: all $(DATA) $(REDO) $(TZLIB) $(MANS) $(TABDATA) + $(ZIC) -y $(YEARISTYPE) \ +- -d $(TZDIR) -l $(LOCALTIME) -p $(POSIXRULES) +- -rm -f $(TZDIR)/iso3166.tab $(TZDIR)/zone.tab +- cp iso3166.tab zone.tab $(TZDIR)/. +- -mkdir $(TOPDIR) $(ETCDIR) +- cp tzselect zic zdump $(ETCDIR)/. +- -mkdir $(TOPDIR) $(MANDIR) \ +- $(MANDIR)/man3 $(MANDIR)/man5 $(MANDIR)/man8 +- -rm -f $(MANDIR)/man3/newctime.3 \ +- $(MANDIR)/man3/newtzset.3 \ +- $(MANDIR)/man5/tzfile.5 \ +- $(MANDIR)/man8/tzselect.8 \ +- $(MANDIR)/man8/zdump.8 \ +- $(MANDIR)/man8/zic.8 +- cp newctime.3 newtzset.3 $(MANDIR)/man3/. +- cp tzfile.5 $(MANDIR)/man5/. +- cp tzselect.8 zdump.8 zic.8 $(MANDIR)/man8/. ++ -d $(DESTDIR)$(TZDIR) -p $(POSIXRULES) ++ ln -sf ..$(TZDIR)$(LOCALTIME) $(DESTDIR)/etc/localtime ++ -rm -f $(DESTDIR)$(TZDIR)/iso3166.tab $(DESTDIR)$(TZDIR)/zone.tab ++ cp iso3166.tab zone.tab $(DESTDIR)$(TZDIR)/. ++ -mkdir $(DESTDIR)$(TOPDIR) $(DESTDIR)$(ETCDIR) ++ cp tzselect zic zdump $(DESTDIR)$(ETCDIR)/. ++ -mkdir $(DESTDIR)$(TOPDIR) $(DESTDIR)$(MANDIR) \ ++ $(DESTDIR)$(MANDIR)/man3 $(DESTDIR)$(MANDIR)/man5 $(DESTDIR)$(MANDIR)/man8 ++ -rm -f $(DESTDIR)$(MANDIR)/man3/newctime.3 \ ++ $(DESTDIR)$(MANDIR)/man3/newtzset.3 \ ++ $(DESTDIR)$(MANDIR)/man5/tzfile.5 \ ++ $(DESTDIR)$(MANDIR)/man8/tzselect.8 \ ++ $(DESTDIR)$(MANDIR)/man8/zdump.8 \ ++ $(DESTDIR)$(MANDIR)/man8/zic.8 ++ cp newctime.3 newtzset.3 $(DESTDIR)$(MANDIR)/man3/. ++ cp tzfile.5 $(DESTDIR)$(MANDIR)/man5/. ++ cp tzselect.8 zdump.8 zic.8 $(DESTDIR)$(MANDIR)/man8/. + + INSTALL: ALL install date.1 +- -mkdir $(TOPDIR) $(BINDIR) +- cp date $(BINDIR)/. +- -mkdir $(TOPDIR) $(MANDIR) $(MANDIR)/man1 +- -rm -f $(MANDIR)/man1/date.1 +- cp date.1 $(MANDIR)/man1/. ++ -mkdir $(DESTDIR)$(TOPDIR) $(DESTDIR)$(BINDIR) ++ cp date $(DESTDIR)$(BINDIR)/. ++ -mkdir $(DESTDIR)$(TOPDIR) $(DESTDIR)$(MANDIR) $(DESTDIR)$(MANDIR)/man1 ++ -rm -f $(DESTDIR)$(MANDIR)/man1/date.1 ++ cp date.1 $(DESTDIR)$(MANDIR)/man1/. + + zdump: $(TZDOBJS) + $(CC) $(CFLAGS) $(LFLAGS) $(TZDOBJS) $(LDLIBS) -o $@ +@@ -317,10 +319,10 @@ + chmod +x yearistype + + posix_only: zic $(TDATA) +- $(ZIC) -y $(YEARISTYPE) -d $(TZDIR) -L /dev/null $(TDATA) ++ $(ZIC) -y $(YEARISTYPE) -d $(DESTDIR)$(TZDIR) -L /dev/null $(TDATA) + + right_only: zic leapseconds $(TDATA) +- $(ZIC) -y $(YEARISTYPE) -d $(TZDIR) -L leapseconds $(TDATA) ++ $(ZIC) -y $(YEARISTYPE) -d $(DESTDIR)$(TZDIR) -L leapseconds $(TDATA) + + # In earlier versions of this makefile, the other two directories were + # subdirectories of $(TZDIR). However, this led to configuration errors. +@@ -332,9 +334,9 @@ + # You must replace all of $(TZDIR) to switch from not using leap seconds + # to using them, or vice versa. + other_two: zic leapseconds $(TDATA) +- $(ZIC) -y $(YEARISTYPE) -d $(TZDIR)-posix -L /dev/null $(TDATA) ++ $(ZIC) -y $(YEARISTYPE) -d $(DESTDIR)$(TZDIR)/posix -L /dev/null $(TDATA) + $(ZIC) -y $(YEARISTYPE) \ +- -d $(TZDIR)-leaps -L leapseconds $(TDATA) ++ -d $(DESTDIR)$(TZDIR)/right -L leapseconds $(TDATA) + + posix_right: posix_only other_two + +@@ -343,10 +345,10 @@ + zones: $(REDO) + + $(TZLIB): $(LIBOBJS) +- -mkdir $(TOPDIR) $(LIBDIR) +- ar ru $@ $(LIBOBJS) ++ -mkdir $(DESTDIR)$(TOPDIR) $(DESTDIR)$(LIBDIR) ++ ar ru $(DESTDIR)$@ $(LIBOBJS) + if [ -x /usr/ucb/ranlib -o -x /usr/bin/ranlib ] ; \ +- then ranlib $@ ; fi ++ then $(RANLIB) $(DESTDIR)$@ ; fi + + # We use the system's logwtmp in preference to ours if available. + diff --git a/base/tzdata/tzdata.conf b/base/tzdata/tzdata.conf new file mode 100644 index 000000000..5fdbc91f1 --- /dev/null +++ b/base/tzdata/tzdata.conf @@ -0,0 +1,40 @@ +# --- SDE-COPYRIGHT-NOTE-BEGIN --- +# This copyright note is auto-generated by ./scripts/Create-CopyPatch. +# +# Filename: package/.../tzdata/tzdata.conf +# Copyright (C) 2008 The OpenSDE Project +# +# More information can be found in the files COPYING and README. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; version 2 of the License. A copy of the +# GNU General Public License can be found in the file COPYING. +# --- SDE-COPYRIGHT-NOTE-END --- + +custextract='tzcode_extract' +hook_add prepatch 5 'tzdata_extract' + +tzcode_extract() { + local taropt_orig="$taropt" + mkdir -p "${xsrctar%%.*}" + taropt="-C ${xsrctar%%.*} $taropt_orig" + autoextract_tar_bz2 "$@" + taropt="$taropt_orig" +} + +tzdata_extract() { + echo_status 'extracting tzdata' + tar -v $taropt $( match_source_file -p tzdata ) +} + +# they add some options when setting CC in the Makefile, we have to override $(cc) +makeopt="cc=$CC AWK=$AWK RANLIB=$RANLIB" +# use `zic` from the PATH, instead of the just compiled one +var_append makeopt ' ' 'zic=zic' + +var_append makeopt ' ' "TOPDIR=/$prefix" +var_append makeopt ' ' "ETCDIR=$sbindir" # no, this is not a typo +var_append makeopt ' ' "TZDIR=$datadir/zoneinfo" + +makeinstopt="$makeopt DESTDIR=$root install" diff --git a/base/tzdata/tzdata.desc b/base/tzdata/tzdata.desc new file mode 100644 index 000000000..5de6e2943 --- /dev/null +++ b/base/tzdata/tzdata.desc @@ -0,0 +1,36 @@ +[COPY] --- SDE-COPYRIGHT-NOTE-BEGIN --- +[COPY] This copyright note is auto-generated by ./scripts/Create-CopyPatch. +[COPY] +[COPY] Filename: package/.../tzdata/tzdata.desc +[COPY] Copyright (C) 2008 The OpenSDE Project +[COPY] +[COPY] More information can be found in the files COPYING and README. +[COPY] +[COPY] This program is free software; you can redistribute it and/or modify +[COPY] it under the terms of the GNU General Public License as published by +[COPY] the Free Software Foundation; version 2 of the License. A copy of the +[COPY] GNU General Public License can be found in the file COPYING. +[COPY] --- SDE-COPYRIGHT-NOTE-END --- + +[I] The zoneinfo database + +[T] The zoneinfo database, also called the tz database, is a collaborative +[T] compilation of information about the world's time zones, primarily +[T] intended for use with computer programs and operating systems. +[T] +[T] Glibc comes with it's own copy if these tools and data files + +[U] http://www.twinsun.com/tz/tz-link.htm + +[A] Arthur David Olson +[M] Alejandro Mery + +[C] extra/base + +[L] PublicDomain +[S] Stable +[V] 2007k +[P] O -1---5---9 200.000 + +[D] 1327969610 tzcode2007k.tar.gz ftp://elsie.nci.nih.gov/pub/ +[D] 1053337723 tzdata2007k.tar.gz ftp://elsie.nci.nih.gov/pub/