[OE-core] [PATCH 1/1] archiver: archived files contain symbol link files

Jian Liu jian.liu at windriver.com
Tue Jan 6 08:44:47 UTC 2015


The archived files contains symbol link files. These files
can not be accessed out of the building host. Copy files
instead of creating symbol link when archiving.

Signed-off-by: Jian Liu <jian.liu at windriver.com>
---
 meta/lib/oe/patch.py | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/meta/lib/oe/patch.py b/meta/lib/oe/patch.py
index b838be8..324a37e 100644
--- a/meta/lib/oe/patch.py
+++ b/meta/lib/oe/patch.py
@@ -432,7 +432,15 @@ class QuiltTree(PatchSet):
         if not self.initialized:
             self.InitFromDir()
         PatchSet.Import(self, patch, force)
-        oe.path.symlink(patch["file"], self._quiltpatchpath(patch["file"]), force=True)
+
+        # if archiver work is being done, symbol link can not be used
+        src_file = patch["file"]
+        des_file = self._quiltpatchpath(patch["file"])
+        if "archiver" in des_file:
+           os.system("cp %s %s"%(src_file,des_file))
+        else:
+           oe.path.symlink(src_file, des_file, force=True)
+
         f = open(os.path.join(self.dir, "patches","series"), "a");
         f.write(os.path.basename(patch["file"]) + " -p" + patch["strippath"]+"\n")
         f.close()
-- 
1.8.3.2




More information about the Openembedded-core mailing list