#!/bin/bash hvbuild() { mkdir -pv ${LFS_TMP}/${PACKAGE} decompress_package ${TZDATA} ${LFS_TMP}/${PACKAGE} cd ${LFS_TMP}/${PACKAGE} ZONEINFO=/usr/share/zoneinfo mkdir -pv ${ZONEINFO}/{posix,right} for tz in etcetera southamerica northamerica europe africa antarctica \ asia australasia backward pacificnew systemv; do zic -L /dev/null -d ${ZONEINFO} -y "sh yearistype.sh" ${tz} zic -L /dev/null -d ${ZONEINFO}/posix -y "sh yearistype.sh" ${tz} zic -L leapseconds -d ${ZONEINFO}/right -y "sh yearistype.sh" ${tz} done cp -v zone.tab zone1970.tab iso3166.tab ${ZONEINFO} zic -d ${ZONEINFO} -p America/New_York if [ -h /etc/localtime ]; then rm /etc/localtime fi # TIMEZONE is defined in sysinfos if [ ! -f ${ZONEINFO}/${TIMEZONE} ]; then echo "Invalid timezone: ${ZONEINFO}/${TIMEZONE}" exit 1 fi ln -s ${ZONEINFO}/${TIMEZONE} /etc/localtime unset ZONEINFO }