aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOla x Nilsson <ola.x.nilsson@axis.com>2017-05-30 12:16:31 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-06-03 23:43:27 +0100
commit061f2aab40fecbfe0dcb928baa95d6b3a6b45eed (patch)
tree570862f21711d92bd79352249d88005a2f9123f5
parent404e8e3661469175e1ea087ebfaf3a7867bf4df2 (diff)
downloadopenembedded-core-contrib-061f2aab40fecbfe0dcb928baa95d6b3a6b45eed.tar.gz
devtool: Compare abspath of both B and S
Either both or none of the paths must be passed through os.path.abspath or things like 'A//B', 'A/./B/', and 'A/B/' in S will cause unintentional mismatches even when B = "${S}". Using os.path.abspath for both seems more likely to be correct as that will also handle the case where ${B} != ${S} but the abspaths are equal. Signed-off-by: Ola x Nilsson <olani@axis.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
-rw-r--r--scripts/lib/devtool/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/lib/devtool/__init__.py b/scripts/lib/devtool/__init__.py
index d646b0cf63..29c4c05071 100644
--- a/scripts/lib/devtool/__init__.py
+++ b/scripts/lib/devtool/__init__.py
@@ -191,7 +191,7 @@ def use_external_build(same_dir, no_same_dir, d):
logger.info('Using source tree as build directory since --same-dir specified')
elif bb.data.inherits_class('autotools-brokensep', d):
logger.info('Using source tree as build directory since recipe inherits autotools-brokensep')
- elif d.getVar('B') == os.path.abspath(d.getVar('S')):
+ elif os.path.abspath(d.getVar('B')) == os.path.abspath(d.getVar('S')):
logger.info('Using source tree as build directory since that would be the default for this recipe')
else:
b_is_s = False