summaryrefslogtreecommitdiff
path: root/source4/scripting/python
diff options
context:
space:
mode:
Diffstat (limited to 'source4/scripting/python')
-rw-r--r--source4/scripting/python/config.mk10
-rw-r--r--source4/scripting/python/modules.c2
-rw-r--r--source4/scripting/python/samba/provision.py32
3 files changed, 10 insertions, 34 deletions
diff --git a/source4/scripting/python/config.mk b/source4/scripting/python/config.mk
index f00b477919..450da0e90a 100644
--- a/source4/scripting/python/config.mk
+++ b/source4/scripting/python/config.mk
@@ -16,7 +16,7 @@ PRIVATE_DEPENDENCIES = LIBNDR LIBLDB SAMDB CREDENTIALS
SWIG_FILE = misc.i
# Swig extensions
-swig: pythonmods
+swig:: pythonmods
.SUFFIXES: _wrap.c .i
@@ -28,13 +28,19 @@ realdistclean::
@-rm -f bin/python/*
# FIXME: Remove _wrap.c files
-pythonmods: $(PYTHON_DSOS)
+pythonmods:: $(PYTHON_DSOS) $(PYTHON_PYS)
PYDOCTOR_MODULES=bin/python/ldb.py bin/python/auth.py bin/python/credentials.py bin/python/registry.py bin/python/tdb.py bin/python/security.py bin/python/events.py bin/python/net.py
pydoctor:: pythonmods
LD_LIBRARY_PATH=bin/shared PYTHONPATH=bin/python pydoctor --make-html --docformat=restructuredtext --add-package scripting/python/samba/ $(addprefix --add-module , $(PYDOCTOR_MODULES))
+installpython:: pythonmods
+ @$(SHELL) $(srcdir)/script/installpython.sh \
+ $(INSTALLPERMS) \
+ $(DESTDIR)$(PYTHONDIR) \
+ scripting/python bin/python
+
clean::
@echo "Removing python modules"
@rm -f bin/python/*
diff --git a/source4/scripting/python/modules.c b/source4/scripting/python/modules.c
index b2dd50b507..fff981e941 100644
--- a/source4/scripting/python/modules.c
+++ b/source4/scripting/python/modules.c
@@ -46,6 +46,8 @@ static void initdcerpc_security(void) {}
extern void initlsa(void);
extern void initsvcctl(void);
extern void initwkssvc(void);
+extern void init_libcli_nbt(void);
+extern void init_libcli_smb(void);
static struct _inittab py_modules[] = { STATIC_LIBPYTHON_MODULES };
diff --git a/source4/scripting/python/samba/provision.py b/source4/scripting/python/samba/provision.py
index 1607cb343b..d59cea121e 100644
--- a/source4/scripting/python/samba/provision.py
+++ b/source4/scripting/python/samba/provision.py
@@ -180,12 +180,6 @@ def provision_paths_from_lp(lp, dnsdomain):
paths.dns_keytab = os.path.join(private_dir, "dns.keytab")
paths.dns = os.path.join(private_dir, dnsdomain + ".zone")
paths.winsdb = os.path.join(private_dir, "wins.ldb")
- paths.ldap_basedn_ldif = os.path.join(private_dir,
- dnsdomain + ".ldif")
- paths.ldap_config_basedn_ldif = os.path.join(private_dir,
- dnsdomain + "-config.ldif")
- paths.ldap_schema_basedn_ldif = os.path.join(private_dir,
- dnsdomain + "-schema.ldif")
paths.s4_ldapi_path = os.path.join(private_dir, "ldapi")
paths.phpldapadminconfig = os.path.join(private_dir,
"phpldapadmin-config.php")
@@ -465,7 +459,6 @@ def setup_samdb(path, setup_path, session_info, credentials, lp,
setup_add_ldif(samdb, setup_path("provision_basedn.ldif"), {
"DOMAINDN": domaindn,
"ACI": aci,
- "EXTENSIBLEOBJECT": "# no objectClass: extensibleObject for local ldb",
"RDN_DC": rdn_dc,
})
@@ -823,31 +816,6 @@ def create_zone_file(path, setup_path, samdb, dnsdomain, domaindn,
})
-def provision_ldapbase(setup_dir, message, paths):
- """Write out a DNS zone file, from the info in the current database."""
- message("Setting up LDAP base entry: %s" % domaindn)
- rdns = domaindn.split(",")
-
- rdn_dc = rdns[0][len("DC="):]
-
- def setup_path(file):
- return os.path.join(setup_dir, file)
-
- setup_file(setup_path("provision_basedn.ldif"),
- paths.ldap_basedn_ldif)
-
- setup_file(setup_path("provision_configuration_basedn.ldif"),
- paths.ldap_config_basedn_ldif)
-
- setup_file(setup_path("provision_schema_basedn.ldif"),
- paths.ldap_schema_basedn_ldif, {
- "SCHEMADN": schemadn,
- "ACI": "# no aci for local ldb",
- "EXTENSIBLEOBJECT": "objectClass: extensibleObject"})
-
- message("Please install the LDIF located in " + paths.ldap_basedn_ldif + ", " + paths.ldap_config_basedn_ldif + " and " + paths.ldap_schema_basedn_ldif + " into your LDAP server, and re-run with --ldap-backend=ldap://my.ldap.server")
-
-
def load_schema(setup_path, samdb, schemadn, netbiosname, configdn):
"""Load schema.