summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/devtool/standard.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index d9b5d15279..a459c7b57c 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -237,13 +237,14 @@ def _extract_source(srctree, keep_temp, devbranch, d):
237 logger.info('Unpacking...') 237 logger.info('Unpacking...')
238 exec_task_func('do_unpack', False) 238 exec_task_func('do_unpack', False)
239 srcsubdir = crd.getVar('S', True) 239 srcsubdir = crd.getVar('S', True)
240 patchsubdir = srcsubdir
240 if srcsubdir != workdir and os.path.dirname(srcsubdir) != workdir: 241 if srcsubdir != workdir and os.path.dirname(srcsubdir) != workdir:
241 # Handle if S is set to a subdirectory of the source 242 # Handle if S is set to a subdirectory of the source
242 srcsubdir = os.path.join(workdir, os.path.relpath(srcsubdir, workdir).split(os.sep)[0]) 243 srcsubdir = os.path.join(workdir, os.path.relpath(srcsubdir, workdir).split(os.sep)[0])
243 244
244 scriptutils.git_convert_standalone_clone(srcsubdir) 245 scriptutils.git_convert_standalone_clone(srcsubdir)
245 246
246 patchdir = os.path.join(srcsubdir, 'patches') 247 patchdir = os.path.join(patchsubdir, 'patches')
247 haspatches = False 248 haspatches = False
248 if os.path.exists(patchdir): 249 if os.path.exists(patchdir):
249 if os.listdir(patchdir): 250 if os.listdir(patchdir):