diff options
author | Richard Braun <rbraun@sceen.net> | 2013-03-07 11:53:41 +0000 |
---|---|---|
committer | Peter Korsgaard <jacmet@sunsite.dk> | 2013-03-10 23:37:04 +0100 |
commit | 1ca9e06f1c9a5ef12feb63711a48379c0eae7e42 (patch) | |
tree | c4220201d308b240c6cbfc0851af7ffb6b605a9f /package/tzdata/tzdata.mk | |
parent | 8d13f6718742553b144946d56205ab23fe1f2972 (diff) | |
download | buildroot-novena-1ca9e06f1c9a5ef12feb63711a48379c0eae7e42.tar.gz buildroot-novena-1ca9e06f1c9a5ef12feb63711a48379c0eae7e42.zip |
package/tzdata: new package
This is the time zone database, used by glibc for translations between
UTC and local time.
Signed-off-by: Richard Braun <rbraun@sceen.net>
[yann.morin.1998@free.fr: use global ZIC, install posix TZ only once]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Danomi Manchego <danomimanchego123@gmail.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/tzdata/tzdata.mk')
-rw-r--r-- | package/tzdata/tzdata.mk | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/package/tzdata/tzdata.mk b/package/tzdata/tzdata.mk new file mode 100644 index 000000000..04d9b2769 --- /dev/null +++ b/package/tzdata/tzdata.mk @@ -0,0 +1,46 @@ +############################################################# +# +# tzdata +# +############################################################# + +TZDATA_VERSION = 2012j +TZDATA_SOURCE = tzdata$(TZDATA_VERSION).tar.gz +TZDATA_SITE = http://www.iana.org/time-zones/repository/releases +TZDATA_DEPENDENCIES = host-zic +TZDATA_LICENSE = Public domain + +TZDATA_DEFAULT_ZONELIST = africa antarctica asia australasia backward etcetera \ + europe factory northamerica pacificnew southamerica + +ifeq ($(call qstrip,$(BR2_PACKAGE_TZDATA_ZONELIST)),default) +TZDATA_ZONELIST = $(TZDATA_DEFAULT_ZONELIST) +else +TZDATA_ZONELIST = $(call qstrip,$(BR2_PACKAGE_TZDATA_ZONELIST)) +endif + +# Don't strip any path components during extraction. +define TZDATA_EXTRACT_CMDS + gzip -d -c $(DL_DIR)/$(TZDATA_SOURCE) \ + | $(TAR) --strip-components=0 -C $(@D) -xf - +endef + +define TZDATA_BUILD_CMDS + (cd $(@D); \ + for zone in $(TZDATA_ZONELIST); do \ + $(ZIC) -d _output/posix -y yearistype.sh $$zone; \ + $(ZIC) -d _output/right -L leapseconds -y yearistype.sh $$zone; \ + done; \ + ) +endef + +define TZDATA_INSTALL_TARGET_CMDS + mkdir -p $(TARGET_DIR)/usr/share/zoneinfo + cp -a $(@D)/_output/* $(TARGET_DIR)/usr/share/zoneinfo + cd $(TARGET_DIR)/usr/share/zoneinfo; \ + for zone in posix/*; do \ + ln -sfn "$${zone}" "$${zone##*/}"; \ + done +endef + +$(eval $(generic-package)) |