diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2015-05-18 20:19:23 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2015-05-19 22:17:47 +0200 |
commit | 0dcf5357959d2bc5cb984eb0276684b56477ed62 (patch) | |
tree | 48be2b1833e3fe4f87c83f5a8e58ff757ea212a6 /third_party | |
parent | 5e0821201cc6b5ffc15b1b795ee85dabd3e9220c (diff) | |
download | samba-0dcf5357959d2bc5cb984eb0276684b56477ed62.tar.gz |
Factor out submodule presence checking.
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue May 19 22:17:48 CEST 2015 on sn-devel-104
Diffstat (limited to 'third_party')
-rw-r--r-- | third_party/wscript | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/third_party/wscript b/third_party/wscript index d41b90698ed..d5b9df7bb96 100644 --- a/third_party/wscript +++ b/third_party/wscript @@ -1,5 +1,6 @@ #!/usr/bin/env python +import samba_git import Utils import os import sys @@ -27,8 +28,7 @@ def find_third_party_module(conf, module, package): try: __import__(module) except ImportError: - if (os.path.isdir(os.path.join(conf.srcdir, ".git")) and - os.path.isfile(os.path.join(conf.srcdir, ".gitmodule"))): + if samba_git.has_submodules(conf.srcdir): raise Utils.WafError("""\ Unable to find Python module '%s'. Please install the system package or check \ out the relevant submodule by running 'git submodule update --init'. |