1
0
mirror of https://github.com/samba-team/samba.git synced 2025-08-02 00:22:11 +03:00

s4:python/samba/__init__.py - import "sys" for "ensure_external_module" method

This commit is contained in:
Matthias Dieter Wallnöfer
2010-03-30 22:06:45 +02:00
parent 488fe76a22
commit 1b6e5a1b8d

View File

@ -25,6 +25,7 @@
__docformat__ = "restructuredText"
import os
import sys
def _in_source_tree():
"""Check whether the script is being run from the source dir. """
@ -33,7 +34,6 @@ def _in_source_tree():
# When running, in-tree, make sure bin/python is in the PYTHONPATH
if _in_source_tree():
import sys
srcdir = "%s/../../.." % os.path.dirname(__file__)
sys.path.append("%s/bin/python" % srcdir)
default_ldb_modules_dir = "%s/bin/modules/ldb" % srcdir