From e7b2e06130fd74a539c58a48c870c9fa1961f699 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 3 Feb 2011 13:49:29 +1100 Subject: s4-provision: cope with top level directory for provision to allow for top level 'make test' we need to cope with two in-tree directory layouts Pair-Programmed-With: Andrew Bartlett --- source4/scripting/python/samba/provision/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source4/scripting/python/samba/provision') diff --git a/source4/scripting/python/samba/provision/__init__.py b/source4/scripting/python/samba/provision/__init__.py index e200083a33..341f822cf2 100644 --- a/source4/scripting/python/samba/provision/__init__.py +++ b/source4/scripting/python/samba/provision/__init__.py @@ -47,6 +47,7 @@ from samba import ( Ldb, check_all_substituted, in_source_tree, + source_tree_topdir, read_and_sub_file, setup_file, substitute_var, @@ -89,8 +90,7 @@ def find_setup_dir(): """Find the setup directory used by provision.""" if in_source_tree(): # In source tree - dirname = os.path.dirname(__file__) - return os.path.normpath(os.path.join(dirname, "../../../../setup")) + return os.path.join(source_tree_topdir(), "source4/setup") else: import sys for prefix in [sys.prefix, -- cgit