lib/ldb: Remove duplicate aspects of build system
authorAndrew Bartlett <abartlet@samba.org>
Sun, 11 Feb 2024 22:16:28 +0000 (11:16 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Fri, 1 Mar 2024 02:41:37 +0000 (02:41 +0000)
We no longer need aspects of our build that made sense for the standalone
operation of LDB now that ldb is only provided as part of Samba.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
lib/ldb/wscript
wscript_build

index 808244090d30ff26b9edd36345b01827d6780b3b..21a57a70975f5700687d12682a1f996a1c99c503 100644 (file)
@@ -10,12 +10,6 @@ from waflib import Errors, Options, Logs, Context
 import shutil
 
 def options(opt):
-    opt.BUILTIN_DEFAULT('replace')
-    opt.PRIVATE_EXTENSION_DEFAULT('ldb', noextension='ldb')
-    opt.RECURSE('lib/tdb')
-    opt.RECURSE('lib/tevent')
-    opt.RECURSE('lib/replace')
-    opt.load('python') # options for disabling pyc or pyo compilation
 
     opt.add_option('--without-ldb-lmdb',
                    help='disable new LMDB backend for LDB',
@@ -23,28 +17,6 @@ def options(opt):
 
 
 def configure(conf):
-    conf.RECURSE('lib/tdb')
-    conf.RECURSE('lib/tevent')
-
-    if conf.CHECK_FOR_THIRD_PARTY():
-        conf.RECURSE('third_party/popt')
-        conf.RECURSE('third_party/cmocka')
-    else:
-        if not conf.CHECK_POPT():
-            raise Errors.WafError('popt development packages have not been found.\nIf third_party is installed, check that it is in the proper place.')
-        else:
-            conf.define('USING_SYSTEM_POPT', 1)
-
-        if not conf.CHECK_CMOCKA():
-            raise Errors.WafError('cmocka development package have not been found.\nIf third_party is installed, check that it is in the proper place.')
-        else:
-            conf.define('USING_SYSTEM_CMOCKA', 1)
-
-    conf.RECURSE('lib/replace')
-    conf.find_program('xsltproc', var='XSLTPROC')
-    conf.SAMBA_CHECK_PYTHON()
-    conf.SAMBA_CHECK_PYTHON_HEADERS()
-
     # where does the default LIBDIR end up? in conf.env somewhere?
     #
     conf.CONFIG_PATH('LDB_MODULESDIR', conf.SUBST_ENV_VAR('MODULESDIR') + '/ldb')
@@ -109,26 +81,10 @@ def configure(conf):
             conf.DEFINE('HAVE_LMDB', '1')
             conf.env.HAVE_LMDB = True
 
-
-    conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True)
-
-    conf.SAMBA_CONFIG_H()
-
-    conf.SAMBA_CHECK_UNDEFINED_SYMBOL_FLAGS()
-
     conf.env.ldb_is_public_library \
         = not samba_bundled.LIB_MUST_BE_PRIVATE(conf, 'ldb')
 
 def build(bld):
-    bld.RECURSE('lib/tevent')
-
-    if bld.CHECK_FOR_THIRD_PARTY():
-        bld.RECURSE('third_party/popt')
-        bld.RECURSE('third_party/cmocka')
-
-    bld.RECURSE('lib/replace')
-    bld.RECURSE('lib/tdb')
-
     if not 'LDB_PACKAGE_VERSION' in bld.env:
         bld.env.LDB_PACKAGE_VERSION = VERSION
 
index dfdffb34c1f52d8b734874376d42cc3e95e26468..3ee2cc5243e2507727f43add1225b8670161e8e8 100644 (file)
@@ -47,6 +47,7 @@ bld.RECURSE('lib/talloc')
 bld.RECURSE('lib/tevent')
 bld.RECURSE('lib/texpect')
 bld.RECURSE('lib/addns')
+bld.RECURSE('lib/tdb')
 bld.RECURSE('lib/ldb')
 bld.RECURSE('lib/param')
 bld.RECURSE('lib/printer_driver')