summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuca Ceresoli <luca@lucaceresoli.net>2013-05-14 02:46:03 (GMT)
committer Peter Korsgaard <jacmet@sunsite.dk>2013-05-14 15:17:09 (GMT)
commit376c3aad61dbeb8e2126e13658fd150b70746afb (patch)
tree204085ba6ac37588ea88fd1e1dac4ab9f618bdf8
parent8d34e073c00236ff41a6df8f0fdd6b0b25dc4ad1 (diff)
downloadbuildroot-376c3aad61dbeb8e2126e13658fd150b70746afb.tar.gz
buildroot-376c3aad61dbeb8e2126e13658fd150b70746afb.tar.bz2
legal-info: fail trying to copy a non-existent license file
If a package's _LICENSE_FILES contains the name of a non-existent file, the make process would continue and return true, unless the non-existent file is the last listed. Fix this wrong beaviour by failing with an error when any of the listed files is missing. Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
-rw-r--r--package/pkg-generic.mk4
1 files changed, 1 insertions, 3 deletions
diff --git a/package/pkg-generic.mk b/package/pkg-generic.mk
index b55b5f0..56fca6b 100644
--- a/package/pkg-generic.mk
+++ b/package/pkg-generic.mk
@@ -508,9 +508,7 @@ ifeq ($(call qstrip,$$($(2)_LICENSE_FILES)),)
@$(call legal-license-nofiles,$$($(2)_RAWNAME))
@$(call legal-warning-pkg,$$($(2)_RAWNAME),cannot save license ($(2)_LICENSE_FILES not defined))
else
- @for F in $$($(2)_LICENSE_FILES); do \
- $(call legal-license-file,$$($(2)_RAWNAME),$$$${F},$$($(2)_DIR)/$$$${F}); \
- done
+ @$(foreach F,$($(2)_LICENSE_FILES),$(call legal-license-file,$$($(2)_RAWNAME),$(F),$$($(2)_DIR)/$(F))$$(sep))
endif
ifeq ($$($(2)_REDISTRIBUTE),YES)
# Copy the source tarball (just hardlink if possible)