[OE-core] [PATCH 1/1] archiver.bbclass: Fix archiver for gcc packages using patched sources

Alejandro Hernandez alejandro.hernandez at linux.intel.com
Tue Sep 29 17:45:37 UTC 2015


gcc packages use a shared source directory, this causes an issue since
the archiver will try to patch the same source several times (one for
each gcc package), producing an error, the archiver class used stamp-base
to check this, nonetheless our gcc packages no longer use stamp-base,
they use gcc-shared instead, which is what broke this functionality
this patch adds a check to see whether or not the source should be patched,
avoiding patching the source when it shouldnt.

[YOCTO #8378]

Signed-off-by: Alejandro Hernandez <alejandro.hernandez at linux.intel.com>
---
 meta/classes/archiver.bbclass | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index eec8024..c3e0f43 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -270,7 +270,9 @@ python do_unpack_and_patch() {
         src = d.getVar('S', True).rstrip('/')
         src_orig = '%s.orig' % src
         oe.path.copytree(src, src_orig)
-    bb.build.exec_func('do_patch', d)
+    # Special case for gcc-shared packages
+    if d.getVar('SRC_URI', True) != "":
+        bb.build.exec_func('do_patch', d)
     # Create the patches
     if d.getVarFlag('ARCHIVER_MODE', 'diff', True) == '1':
         bb.note('Creating diff gz...')
-- 
1.8.4.5




More information about the Openembedded-core mailing list