summaryrefslogtreecommitdiff
path: root/source4/scripting
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2011-07-21 09:48:30 +1000
committerAndrew Tridgell <tridge@samba.org>2011-07-28 15:20:52 +1000
commit02667cbe2627898fb2937f649015373a1d450de3 (patch)
tree12252756f5df0fa42f2d1c98114f359ee555925d /source4/scripting
parent35747fe6f05b0d39c4d768d0e88ed6e23aa7875f (diff)
downloadsamba-02667cbe2627898fb2937f649015373a1d450de3.tar.gz
samba-02667cbe2627898fb2937f649015373a1d450de3.tar.bz2
samba-02667cbe2627898fb2937f649015373a1d450de3.zip
samba-tool: Replace C version of samba-tool with python version
C version of samba-tool is now called samba-tool-c, which will be removed as soon as all the samba-tool commands are ported to python. Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'source4/scripting')
-rwxr-xr-xsource4/scripting/bin/samba-tool (renamed from source4/scripting/python/samba/samba-tool.py)5
-rw-r--r--source4/scripting/bin/wscript_build1
-rw-r--r--source4/scripting/wscript_build2
3 files changed, 4 insertions, 4 deletions
diff --git a/source4/scripting/python/samba/samba-tool.py b/source4/scripting/bin/samba-tool
index 494654a78d..9735335af5 100755
--- a/source4/scripting/python/samba/samba-tool.py
+++ b/source4/scripting/bin/samba-tool
@@ -18,10 +18,9 @@
#
import sys
-from os.path import dirname
-samba_pymodule_dir = dirname(dirname(sys.argv[0]))
-sys.path.append(samba_pymodule_dir)
+# Find right direction when running from source tree
+sys.path.insert(0, "bin/python")
from samba import netcmd
from samba.netcmd import Command, CommandError, Option
diff --git a/source4/scripting/bin/wscript_build b/source4/scripting/bin/wscript_build
index e52b32bc02..87387054b3 100644
--- a/source4/scripting/bin/wscript_build
+++ b/source4/scripting/bin/wscript_build
@@ -3,3 +3,4 @@
bld.SAMBA_SCRIPT('samba_dnsupdate', pattern='samba_dnsupdate', installdir='.')
bld.SAMBA_SCRIPT('samba_spnupdate', pattern='samba_spnupdate', installdir='.')
bld.SAMBA_SCRIPT('upgradeprovision', pattern='upgradeprovision', installdir='.')
+bld.SAMBA_SCRIPT('samba-tool', pattern='samba-tool', installdir='.')
diff --git a/source4/scripting/wscript_build b/source4/scripting/wscript_build
index d94fc4fe9c..90f1f2f021 100644
--- a/source4/scripting/wscript_build
+++ b/source4/scripting/wscript_build
@@ -2,7 +2,7 @@
from samba_utils import MODE_755
-bld.INSTALL_FILES('${SBINDIR}','bin/upgradeprovision bin/samba_dnsupdate bin/samba_spnupdate',
+bld.INSTALL_FILES('${SBINDIR}','bin/upgradeprovision bin/samba_dnsupdate bin/samba_spnupdate bin/samba-tool',
chmod=MODE_755, python_fixup=True, flat=True)
bld.RECURSE('bin')