From 5323695e315c13f8bb8750cb64c62c26f089780c Mon Sep 17 00:00:00 2001 From: Tobias Ulmer Date: Sun, 18 Apr 2010 06:18:55 +0200 Subject: [PATCH] collect_project: bugfix: invalid makefile code was generated for archive files configured to be copied, not unpacked. Signed-off-by: Gordon Hecker --- Changelog | 1 + local/files.lua | 23 +++++++++++++---------- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/Changelog b/Changelog index eeaae9c..6111d48 100644 --- a/Changelog +++ b/Changelog @@ -1,4 +1,5 @@ NEXT: + * bugfixes in collect_project: Copying files was not handled correctly e2factory-2.3.4 * version information for plugins is displayed now when requested diff --git a/local/files.lua b/local/files.lua index 6e9250d..20444f3 100644 --- a/local/files.lua +++ b/local/files.lua @@ -392,18 +392,21 @@ function files.toresult(info, sourcename, sourceset, directory) "\tcd source && sha1sum -c '%s'\n", e2lib.basename(checksum_file))) end - local c = e2lib.howtounpack( - string.format("%s/%s", destdir, + if file.unpack then + local c = e2lib.howtounpack( + string.format("%s/%s", destdir, e2lib.basename(file.location)), - string.format("%s/%s", source, + string.format("%s/%s", source, e2lib.basename(file.location)), - string.format("$(BUILD)")) - if c then - f:write(string.format("\t%s\n", c)) - end - if file.unpack and file.unpack ~= sourcename then - f:write(string.format( - "\tln -s %s $(BUILD)/%s\n", file.unpack, sourcename)) + string.format("$(BUILD)")) + if c then + f:write(string.format("\t%s\n", c)) + end + if file.unpack ~= sourcename then + f:write(string.format( + "\tln -s %s $(BUILD)/%s\n", file.unpack, + sourcename)) + end end if file.copy then f:write(string.format( -- 2.39.5