ldb: Fix dependencies when building with system ldb.
authorJelmer Vernooij <jelmer@samba.org>
Mon, 31 May 2010 14:05:41 +0000 (16:05 +0200)
committerJelmer Vernooij <jelmer@samba.org>
Mon, 31 May 2010 17:22:03 +0000 (19:22 +0200)
source4/auth/wscript_build
source4/dsdb/wscript_build
source4/lib/ldb/tools/cmdline.c
source4/lib/ldb/tools/ldbedit.c
source4/lib/ldb/tools/ldbsearch.c
source4/lib/ldb/tools/ldbtest.c
source4/lib/ldb/wscript
source4/scripting/python/wscript_build

index 349171e0814412f52ad26ff131936408009d985e..db8fdf8b00bb1577793017116fbf0385159c2e17 100644 (file)
@@ -12,7 +12,7 @@ bld.SAMBA_SUBSYSTEM('auth_session',
        public_deps='CREDENTIALS',
        public_headers='session.h',
         header_path='samba',
-       deps='SAMDB'
+       deps='SAMDB auth_sam'
        )
 
 
index 1bf8413acc5d913b4673e163e4e026139e2aee28..0a1ea1cc7f446b53a11c565cdd8df4f86f09548b 100644 (file)
@@ -51,6 +51,6 @@ bld.SAMBA_MODULE('DNS_UPDATE_SRV',
 
 bld.SAMBA_PYTHON('python_dsdb',
                  source='pydsdb.c',
-                 deps='SAMDB pyldb',
+                 deps='SAMDB pyldb_util',
                  realname='samba/dsdb.so'
                  )
index 180923fc63688858ceebcb79205ac83b55a96823..c2b595f329d746d5c6991bac1127591803c30554 100644 (file)
    License along with this library; if not, see <http://www.gnu.org/licenses/>.
 */
 
-#include "ldb_includes.h"
-#include "ldb.h"
-#include "tools/cmdline.h"
-
 #if (_SAMBA_BUILD_ >= 4)
 #include "includes.h"
+#include <ldb.h>
 #include "lib/cmdline/popt_common.h"
 #include "lib/ldb-samba/ldif_handlers.h"
 #include "auth/gensec/gensec.h"
 #include "librpc/gen_ndr/drsblobs.h"
 #include "dsdb/schema/schema.h"
 #include "dsdb/common/proto.h"
+#else
+#include "ldb_includes.h"
+#include "ldb.h"
 #endif
 
+#include "tools/cmdline.h"
+
 static struct ldb_cmdline options; /* needs to be static for older compilers */
 
 static struct poptOption popt_options[] = {
index 66354666a6c0b20ddbd09decaa95bd57a01e483c..f28964b06a1c0fc87abafa2c9cf4e9f1cbdc1578 100644 (file)
  *
  *  Author: Andrew Tridgell
  */
+
+#ifdef _SAMBA_BUILD_
+#include "includes.h"
+#include <system/filesys.h>
+#else
 #include "ldb_includes.h"
+#endif
+
 #include "ldb.h"
 #include "tools/cmdline.h"
 #include "tools/ldbutil.h"
index 179646c73fbe3b8999ac6ebfeafaccca0a6b1e9c..55144a7a8c96b7014e03dc4acc4973c3e9454346 100644 (file)
  *  Author: Andrew Tridgell
  */
 
+#ifdef _SAMBA_BUILD_
+#include "includes.h"
+#include <ldb.h>
+#else
 #include "ldb_includes.h"
 #include "ldb.h"
+#endif
+
 #include "tools/cmdline.h"
 
 static void usage(void)
index 077eb987acfbb74c3c26d60b9d67f4b3932ce2e7..b76889c61fbdf3b8d367071ca1c60dd90ee111dc 100644 (file)
  *  Author: Andrew Tridgell
  */
 
+#ifdef _SAMBA_BUILD_
+#include "includes.h"
+#else
 #include "ldb_includes.h"
+#endif
+
 #include "ldb.h"
 #include "tools/cmdline.h"
 
index 2d54b61d0c751db3df2cbb05eba5cb1bd6522935..a1eca78268ef0c2e95f72f6f450a4a153cd75b88 100644 (file)
@@ -152,7 +152,6 @@ def build(bld):
 
     ldb_deps = 'tevent LIBLDB'
     if s4_build:
-        ldb_deps += ' LDBSAMBA POPT_CREDENTIALS POPT_SAMBA LIBCMDLINE_CREDENTIALS gensec'
         abi_file='ABI/ldb-samba4-%s.sigs' % VERSION
     else:
         abi_file='ABI/ldb-%s.sigs' % VERSION
@@ -172,9 +171,18 @@ def build(bld):
                           vnum=VERSION, manpages='man/ldb.3',
                           is_bundled=not bld.env.standalone_ldb)
 
+        bld.SAMBA_PYTHON('pyldb', 'pyldb.c',
+                         deps='ldb',
+                         realname='ldb.so')
+
+    extra_cmdline_deps = ''
+    if s4_build:
+        extra_cmdline_deps += ' LDBSAMBA POPT_SAMBA POPT_CREDENTIALS ' \
+                               'LIBCMDLINE_CREDENTIALS gensec'
+
     bld.SAMBA_SUBSYSTEM('LIBLDB_CMDLINE',
                         'tools/ldbutil.c tools/cmdline.c',
-                        'ldb dl popt')
+                        'ldb dl popt' + extra_cmdline_deps)
 
     LDB_TOOLS='ldbadd ldbsearch ldbdel ldbmodify ldbedit ldbrename'
     for t in LDB_TOOLS.split():
@@ -185,10 +193,6 @@ def build(bld):
     bld.SAMBA_BINARY('ldbtest', 'tools/ldbtest.c', deps='LIBLDB_CMDLINE',
                      install=False)
 
-    bld.SAMBA_PYTHON('pyldb', 'pyldb.c',
-                     deps='ldb',
-                     realname='ldb.so')
-
 
 def test(ctx):
     '''run ldb testsuite'''
index 0709c426a779fdfd173a39ae8573c133f594bfc5..af3c6ed9177f65285b6c54c7e026a82392b34b0a 100644 (file)
@@ -24,7 +24,7 @@ bld.SAMBA_PYTHON('python_uuid',
 
 bld.SAMBA_PYTHON('python_glue',
                  source='pyglue.c',
-                 deps='LIBNDR ldb SAMDB CREDENTIALS pyldb python_dcerpc_misc python_dcerpc_security pyauth pyldb_util pyparam_util',
+                 deps='LIBNDR ldb SAMDB CREDENTIALS python_dcerpc_misc python_dcerpc_security pyauth pyldb_util pyparam_util',
                  realname='samba/_glue.so'
        )