$(TARGET_DIR)/usr/share/zoneinfo/iso3166.tab
mkdir -p $(TARGET_DIR)/usr/share/zoneinfo/uclibc
cp -a $(@D)/output/* $(TARGET_DIR)/usr/share/zoneinfo/uclibc
- if [ -n "$(TZ_LOCALTIME)" ]; then \
- if [ ! -f $(TARGET_DIR)/usr/share/zoneinfo/uclibc/$(TZ_LOCALTIME) ]; then \
- printf "Error: '%s' is not a valid timezone, check your BR2_TARGET_LOCALTIME setting\n" \
- "$(TZ_LOCALTIME)"; \
- exit 1; \
- fi; \
- cd $(TARGET_DIR)/etc; \
- ln -sf ../usr/share/zoneinfo/uclibc/$(TZ_LOCALTIME) TZ; \
+ if [ ! -f $(TARGET_DIR)/usr/share/zoneinfo/uclibc/$(TZ_LOCALTIME) ]; then \
+ printf "Error: '%s' is not a valid timezone, check your BR2_TARGET_LOCALTIME setting\n" \
+ "$(TZ_LOCALTIME)"; \
+ exit 1; \
fi
+ ln -sf ../usr/share/zoneinfo/uclibc/$(TZ_LOCALTIME) $(TARGET_DIR)/etc/TZ
endef
$(eval $(generic-package))
for zone in posix/*; do \
ln -sfn "$${zone}" "$${zone##*/}"; \
done
- if [ -n "$(TZDATA_LOCALTIME)" ]; then \
- if [ ! -f $(TARGET_DIR)/usr/share/zoneinfo/$(TZDATA_LOCALTIME) ]; then \
- printf "Error: '%s' is not a valid timezone, check your BR2_TARGET_LOCALTIME setting\n" \
- "$(TZDATA_LOCALTIME)"; \
- exit 1; \
- fi; \
- cd $(TARGET_DIR)/etc; \
- ln -sf ../usr/share/zoneinfo/$(TZDATA_LOCALTIME) localtime; \
- echo "$(TZDATA_LOCALTIME)" >timezone; \
+ if [ ! -f $(TARGET_DIR)/usr/share/zoneinfo/$(TZDATA_LOCALTIME) ]; then \
+ printf "Error: '%s' is not a valid timezone, check your BR2_TARGET_LOCALTIME setting\n" \
+ "$(TZDATA_LOCALTIME)"; \
+ exit 1; \
fi
+ ln -sf ../usr/share/zoneinfo/$(TZDATA_LOCALTIME) $(TARGET_DIR)/etc/localtime
+ echo "$(TZDATA_LOCALTIME)" >$(TARGET_DIR)/etc/timezone
endef
define HOST_TZDATA_BUILD_CMDS
help
The time zone to install as the default local time, expressed as a
tzdata location, such as:
+ Etc/UTC (the default)
GMT
Europe/Paris
America/New_York
Pacific/Wallis
...
- If empty, no local time will be set, and the dates will be
- expressed in UTC.
-
endif # BR2_TARGET_TZ_INFO
config BR2_ROOTFS_USERS_TABLES