aboutsummaryrefslogtreecommitdiff
path: root/package/tzdata
diff options
context:
space:
mode:
authorGravatar Yann E. MORIN <yann.morin.1998@free.fr>2014-11-18 19:38:27 +0100
committerGravatar Peter Korsgaard <peter@korsgaard.com>2014-11-18 21:50:05 +0100
commit20271a0011c21ed15704017ec83be6d21b47c1ac (patch)
tree5223ad8e6edd4944240496dfa3841517df778290 /package/tzdata
parent2c7151792024d1d05f00ee8a95e9dd4282510a3e (diff)
downloadbuildroot-20271a0011c21ed15704017ec83be6d21b47c1ac.tar.gz
buildroot-20271a0011c21ed15704017ec83be6d21b47c1ac.tar.bz2
package/tzdata: fix installation commands
If the destination directory already exists (e.g. because of a re-run or a custom skeleton), then the zoneinfo files will be installed in a sub-directory of where we are trying to install them. Fix that by creating the destination directory and copying the content of the source directory. Also fix the host install commands to match what we do in the target install commands. Reported-by: Martin Dorwig <dorwig@tetronik.com> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Diffstat (limited to 'package/tzdata')
-rw-r--r--package/tzdata/tzdata.mk6
1 files changed, 3 insertions, 3 deletions
diff --git a/package/tzdata/tzdata.mk b/package/tzdata/tzdata.mk
index 47e29c0cc5..d0aa8570b3 100644
--- a/package/tzdata/tzdata.mk
+++ b/package/tzdata/tzdata.mk
@@ -26,8 +26,8 @@ TZDATA_LOCALTIME = $(call qstrip,$(BR2_TARGET_LOCALTIME))
TZDATA_EXTRACT_CMDS =
define TZDATA_INSTALL_TARGET_CMDS
- $(INSTALL) -d -m 0755 $(TARGET_DIR)/usr/share
- cp -a $(HOST_DIR)/usr/share/zoneinfo $(TARGET_DIR)/usr/share/zoneinfo
+ $(INSTALL) -d -m 0755 $(TARGET_DIR)/usr/share/zoneinfo
+ cp -a $(HOST_DIR)/usr/share/zoneinfo/* $(TARGET_DIR)/usr/share/zoneinfo
cd $(TARGET_DIR)/usr/share/zoneinfo; \
for zone in posix/*; do \
ln -sfn "$${zone}" "$${zone##*/}"; \
@@ -59,7 +59,7 @@ define HOST_TZDATA_BUILD_CMDS
endef
define HOST_TZDATA_INSTALL_CMDS
- mkdir -p $(HOST_DIR)/usr/share/zoneinfo
+ $(INSTALL) -d -m 0755 $(HOST_DIR)/usr/share/zoneinfo
cp -a $(@D)/_output/* $(@D)/*.tab $(HOST_DIR)/usr/share/zoneinfo
endef