summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Korsgaard <peter@korsgaard.com>2014-03-25 06:18:15 (GMT)
committer Peter Korsgaard <peter@korsgaard.com>2014-03-25 06:18:15 (GMT)
commit2e628372d34d9e77727185aaf47c82a439a22244 (patch)
treefe5193deb8ba188c47fe4c13c51a20c5d60a715c
parent482757f537bc0364bf765f0da02310b6a48bf06e (diff)
downloadbuildroot-2e628372d34d9e77727185aaf47c82a439a22244.tar.gz
buildroot-2e628372d34d9e77727185aaf47c82a439a22244.tar.bz2
uboot: unbreak legal info for legacy versions
Fixes #6986 Prior to u-boot 2013.10, the GPL license text was stored in COPYING and not Licenses/gpl-2.0.txt, breaking legal-info. Work around it by simply copying the file from the old location to the new if present. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
-rw-r--r--boot/uboot/uboot.mk10
1 files changed, 10 insertions, 0 deletions
diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk
index 2174584..da67706 100644
--- a/boot/uboot/uboot.mk
+++ b/boot/uboot/uboot.mk
@@ -75,6 +75,16 @@ $(if $(call qstrip,$(2)),
@echo '#define $(strip $(1)) $(call qstrip,$(2))' >> $(@D)/include/config.h)
endef
+# prior to u-boot 2013.10 the license info was in COPYING. Copy it so
+# legal-info finds it
+define UBOOT_COPY_OLD_LICENSE_FILE
+ if [ -f $(@D)/COPYING ]; then \
+ $(INSTALL) -m 0644 -D $(@D)/COPYING $(@D)/Licenses/gpl-2.0.txt; \
+ fi
+endef
+
+UBOOT_POST_EXTRACT_HOOKS += UBOOT_COPY_OLD_LICENSE_FILE
+
ifneq ($(call qstrip,$(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR)),)
define UBOOT_APPLY_CUSTOM_PATCHES
support/scripts/apply-patches.sh $(@D) $(BR2_TARGET_UBOOT_CUSTOM_PATCH_DIR) \