summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorTomasz Dziendzielski <tomasz.dziendzielski@gmail.com>2021-01-21 23:31:53 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-02-05 23:35:18 +0000
commit8e23c6ec3721d288f7ebf99a33b64b2090d1dfc3 (patch)
treef4e6869f248eab6394c025008d7346a8425b591d /scripts
parent558a9149e06e44720a1d23d0b078bee3b206f37a (diff)
downloadpoky-8e23c6ec3721d288f7ebf99a33b64b2090d1dfc3.tar.gz
devtool: Fix file:// fetcher symlink directory structure
Add relative path if file is under directory. [YOCTO #13738] (From OE-Core rev: 19ddacc1b38f9ebb86a9359963ccc3c707f7125e) (From OE-Core rev: a6a4e1350c6c8170648a9e910b06e6534d11f926) Signed-off-by: Tomasz Dziendzielski <tomasz.dziendzielski@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 3a220f1e411767cbf9e7099c18d94a12171c1093) Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/devtool/standard.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index f7d8a82117..7b62b7e7b8 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -474,7 +474,11 @@ def symlink_oelocal_files_srctree(rd,srctree):
474 destpth = os.path.join(srctree, relpth, fn) 474 destpth = os.path.join(srctree, relpth, fn)
475 if os.path.exists(destpth): 475 if os.path.exists(destpth):
476 os.unlink(destpth) 476 os.unlink(destpth)
477 os.symlink('oe-local-files/%s' % fn, destpth) 477 if relpth != '.':
478 back_relpth = os.path.relpath(local_files_dir, root)
479 os.symlink('%s/oe-local-files/%s/%s' % (back_relpth, relpth, fn), destpth)
480 else:
481 os.symlink('oe-local-files/%s' % fn, destpth)
478 addfiles.append(os.path.join(relpth, fn)) 482 addfiles.append(os.path.join(relpth, fn))
479 if addfiles: 483 if addfiles:
480 bb.process.run('git add %s' % ' '.join(addfiles), cwd=srctree) 484 bb.process.run('git add %s' % ' '.join(addfiles), cwd=srctree)