diff options
Diffstat (limited to 'source4/scripting')
-rw-r--r-- | source4/scripting/ejs/config.mk | 59 | ||||
-rw-r--r-- | source4/scripting/ejs/ejsnet/config.mk | 14 | ||||
-rw-r--r-- | source4/scripting/ejs/smbcalls.c | 27 | ||||
-rw-r--r-- | source4/scripting/python/config.mk | 42 | ||||
-rw-r--r-- | source4/scripting/python/modules.c | 1 |
5 files changed, 78 insertions, 65 deletions
diff --git a/source4/scripting/ejs/config.mk b/source4/scripting/ejs/config.mk index c1f07367fb..0d10fc6e3a 100644 --- a/source4/scripting/ejs/config.mk +++ b/source4/scripting/ejs/config.mk @@ -1,84 +1,85 @@ [SUBSYSTEM::EJSRPC] -OBJ_FILES = \ - ejsrpc.o + +EJSRPC_OBJ_FILES = scripting/ejs/ejsrpc.o [MODULE::smbcalls_config] -OBJ_FILES = smbcalls_config.o OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_config +smbcalls_config_OBJ_FILES = scripting/ejs/smbcalls_config.o + [MODULE::smbcalls_ldb] -OBJ_FILES = smbcalls_ldb.o OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_ldb PRIVATE_DEPENDENCIES = LIBLDB SAMDB LIBNDR +smbcalls_ldb_OBJ_FILES = scripting/ejs/smbcalls_ldb.o + [MODULE::smbcalls_reg] -OBJ_FILES = smbcalls_reg.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_reg PRIVATE_DEPENDENCIES = registry SAMDB LIBNDR +smbcalls_reg_OBJ_FILES = scripting/ejs/smbcalls_reg.o + [MODULE::smbcalls_nbt] -OBJ_FILES = smbcalls_nbt.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_nbt +smbcalls_nbt_OBJ_FILES = scripting/ejs/smbcalls_nbt.o + [MODULE::smbcalls_rand] -OBJ_FILES = smbcalls_rand.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_random +smbcalls_rand_OBJ_FILES = scripting/ejs/smbcalls_rand.o + [MODULE::smbcalls_nss] -OBJ_FILES = smbcalls_nss.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_nss PRIVATE_DEPENDENCIES = NSS_WRAPPER +smbcalls_nss_OBJ_FILES = scripting/ejs/smbcalls_nss.o + [MODULE::smbcalls_data] -OBJ_FILES = smbcalls_data.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_datablob +smbcalls_data_OBJ_FILES = scripting/ejs/smbcalls_data.o + [MODULE::smbcalls_auth] -OBJ_FILES = smbcalls_auth.o OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_auth -PRIVATE_DEPENDENCIES = auth +PRIVATE_DEPENDENCIES = service_auth + +smbcalls_auth_OBJ_FILES = scripting/ejs/smbcalls_auth.o [MODULE::smbcalls_string] -OBJ_FILES = smbcalls_string.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_string +smbcalls_string_OBJ_FILES = scripting/ejs/smbcalls_string.o + [MODULE::smbcalls_sys] -OBJ_FILES = smbcalls_sys.o SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_system +smbcalls_sys_OBJ_FILES = scripting/ejs/smbcalls_sys.o + mkinclude ejsnet/config.mk [SUBSYSTEM::smbcalls] PRIVATE_PROTO_HEADER = proto.h -OBJ_FILES = \ - smbcalls.o \ - smbcalls_cli.o \ - smbcalls_rpc.o \ - smbcalls_options.o \ - smbcalls_creds.o \ - smbcalls_param.o \ - mprutil.o \ - literal.o PRIVATE_DEPENDENCIES = \ EJS LIBSAMBA-UTIL \ EJSRPC MESSAGING \ @@ -87,12 +88,22 @@ PRIVATE_DEPENDENCIES = \ dcerpc \ NDR_TABLE +smbcalls_OBJ_FILES = $(addprefix scripting/ejs/, \ + smbcalls.o \ + smbcalls_cli.o \ + smbcalls_rpc.o \ + smbcalls_options.o \ + smbcalls_creds.o \ + smbcalls_param.o \ + mprutil.o \ + literal.o) + ####################### # Start BINARY SMBSCRIPT [BINARY::smbscript] INSTALLDIR = BINDIR -OBJ_FILES = \ - smbscript.o PRIVATE_DEPENDENCIES = EJS LIBSAMBA-UTIL smbcalls LIBSAMBA-CONFIG # End BINARY SMBSCRIPT ####################### + +smbscript_OBJ_FILES = scripting/ejs/smbscript.o diff --git a/source4/scripting/ejs/ejsnet/config.mk b/source4/scripting/ejs/ejsnet/config.mk index 249a33121d..85a5b2bf09 100644 --- a/source4/scripting/ejs/ejsnet/config.mk +++ b/source4/scripting/ejs/ejsnet/config.mk @@ -1,11 +1,13 @@ [MODULE::smbcalls_net] -OBJ_FILES = \ - net_ctx.o \ - net_user.o \ - mpr_user.o \ - net_host.o \ - mpr_host.o SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_net PRIVATE_PROTO_HEADER = proto.h PRIVATE_DEPENDENCIES = LIBSAMBA-NET LIBCLI_SMB CREDENTIALS + +smbcalls_net_OBJ_FILES = $(addprefix scripting/ejs/ejsnet/, \ + net_ctx.o \ + net_user.o \ + mpr_user.o \ + net_host.o \ + mpr_host.o) + diff --git a/source4/scripting/ejs/smbcalls.c b/source4/scripting/ejs/smbcalls.c index 63a80e17db..98d6be07bf 100644 --- a/source4/scripting/ejs/smbcalls.c +++ b/source4/scripting/ejs/smbcalls.c @@ -23,7 +23,6 @@ #include "includes.h" #include "param/param.h" #include "scripting/ejs/smbcalls.h" -#include "build.h" #include "version.h" /* @@ -173,6 +172,32 @@ _PUBLIC_ void ejs_exception(const char *reason) */ void smb_setup_ejs_functions(void (*exception_handler)(const char *)) { + extern NTSTATUS ejs_init_security(void); + extern NTSTATUS ejs_init_initshutdown(void); + extern NTSTATUS smb_setup_ejs_reg(void); + extern NTSTATUS smb_setup_ejs_string(void); + extern NTSTATUS ejs_init_lsarpc(void); + extern NTSTATUS ejs_init_rpcecho(void); + extern NTSTATUS ejs_init_winreg(void); + extern NTSTATUS smb_setup_ejs_random(void); + extern NTSTATUS smb_setup_ejs_config(void); + extern NTSTATUS ejs_init_misc(void); + extern NTSTATUS ejs_init_netdfs(void); + extern NTSTATUS smb_setup_ejs_datablob(void); + extern NTSTATUS smb_setup_ejs_auth(void); + extern NTSTATUS smb_setup_ejs_nss(void); + extern NTSTATUS ejs_init_samr(void); + extern NTSTATUS ejs_init_wkssvc(void); + extern NTSTATUS smb_setup_ejs_system(void); + extern NTSTATUS smb_setup_ejs_ldb(void); + extern NTSTATUS ejs_init_svcctl(void); + extern NTSTATUS smb_setup_ejs_nbt(void); + extern NTSTATUS smb_setup_ejs_net(void); + extern NTSTATUS ejs_init_srvsvc(void); + extern NTSTATUS ejs_init_netlogon(void); + extern NTSTATUS ejs_init_drsuapi(void); + extern NTSTATUS ejs_init_irpc(void); + extern NTSTATUS ejs_init_eventlog(void); init_module_fn static_init[] = { STATIC_smbcalls_MODULES }; init_module_fn *shared_init; diff --git a/source4/scripting/python/config.mk b/source4/scripting/python/config.mk index 09c77813ca..a0f5caad3b 100644 --- a/source4/scripting/python/config.mk +++ b/source4/scripting/python/config.mk @@ -1,49 +1,25 @@ [BINARY::smbpython] PRIVATE_DEPENDENCIES = LIBPYTHON -OBJ_FILES = smbpython.o + +smbpython_OBJ_FILES = scripting/python/smbpython.o [SUBSYSTEM::LIBPYTHON] PUBLIC_DEPENDENCIES = EXT_LIB_PYTHON INIT_FUNCTION_SENTINEL = { NULL, NULL } -OBJ_FILES = modules.o pytalloc.o + +LIBPYTHON_OBJ_FILES = $(addprefix scripting/python/, modules.o pytalloc.o) [PYTHON::python_uuid] PRIVATE_DEPENDENCIES = LIBNDR -OBJ_FILES = uuidmodule.o + +python_uuid_OBJ_FILES = scripting/python/uuidmodule.o [PYTHON::python_misc] PRIVATE_DEPENDENCIES = LIBNDR LIBLDB SAMDB CREDENTIALS SWIG_FILE = misc.i -# Swig extensions -swig:: pythonmods - -.SUFFIXES: _wrap.c .i - -.i_wrap.c: - [ "$(SWIG)" = "no" ] || $(SWIG) -O -Wall -I$(srcdir)/scripting/swig -python -keyword $< - -realdistclean:: - @echo "Removing SWIG output files" - # FIXME: Remove _wrap.c files - -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 --project-name=Samba --make-html --docformat=restructuredtext --add-package scripting/python/samba/ $(addprefix --add-module , $(PYDOCTOR_MODULES)) - -bin/python/%.py: - mkdir -p $(@D) - cp $< $@ +python_misc_OBJ_FILES = scripting/python/misc_wrap.o -installpython:: pythonmods - @$(SHELL) $(srcdir)/script/installpython.sh \ - $(INSTALLPERMS) \ - $(DESTDIR)$(PYTHONDIR) \ - scripting/python bin/python +_PY_FILES = $(shell find scripting/python -name "*.py") -clean:: - @echo "Removing python modules" - @rm -rf bin/python/* +$(foreach pyfile, $(_PY_FILES),$(eval $(call python_py_module_template,$(patsubst scripting/python/%,%,$(pyfile)),$(pyfile)))) diff --git a/source4/scripting/python/modules.c b/source4/scripting/python/modules.c index 2ecad20b8e..2c10a35c60 100644 --- a/source4/scripting/python/modules.c +++ b/source4/scripting/python/modules.c @@ -19,7 +19,6 @@ #include "includes.h" #include <Python.h> -#include "build.h" extern void init_ldb(void); extern void init_security(void); |