diff options
-rw-r--r-- | meta/classes/externalsrc.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/externalsrc.bbclass b/meta/classes/externalsrc.bbclass index 0deb5dbf5f..26c5803ee6 100644 --- a/meta/classes/externalsrc.bbclass +++ b/meta/classes/externalsrc.bbclass | |||
@@ -230,7 +230,7 @@ def srctree_hash_files(d, srcdir=None): | |||
230 | env['GIT_INDEX_FILE'] = tmp_index.name | 230 | env['GIT_INDEX_FILE'] = tmp_index.name |
231 | subprocess.check_output(['git', 'add', '-A', '.'], cwd=s_dir, env=env) | 231 | subprocess.check_output(['git', 'add', '-A', '.'], cwd=s_dir, env=env) |
232 | git_sha1 = subprocess.check_output(['git', 'write-tree'], cwd=s_dir, env=env).decode("utf-8") | 232 | git_sha1 = subprocess.check_output(['git', 'write-tree'], cwd=s_dir, env=env).decode("utf-8") |
233 | if os.path.exists(os.path.join(s_dir, ".gitmodules")): | 233 | if os.path.exists(os.path.join(s_dir, ".gitmodules")) and os.path.getsize(os.path.join(s_dir, ".gitmodules")) > 0: |
234 | submodule_helper = subprocess.check_output(["git", "config", "--file", ".gitmodules", "--get-regexp", "path"], cwd=s_dir, env=env).decode("utf-8") | 234 | submodule_helper = subprocess.check_output(["git", "config", "--file", ".gitmodules", "--get-regexp", "path"], cwd=s_dir, env=env).decode("utf-8") |
235 | for line in submodule_helper.splitlines(): | 235 | for line in submodule_helper.splitlines(): |
236 | module_dir = os.path.join(s_dir, line.rsplit(maxsplit=1)[1]) | 236 | module_dir = os.path.join(s_dir, line.rsplit(maxsplit=1)[1]) |