From e0905c30908b4d621030689d33de28a13c04a690 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 20 Oct 2008 13:19:39 +0200 Subject: Use tables in Samba 3 ndrdump. --- source3/Makefile.in | 12 +++++- source3/librpc/gen_ndr/tables.c | 83 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 93 insertions(+), 2 deletions(-) create mode 100644 source3/librpc/gen_ndr/tables.c (limited to 'source3') diff --git a/source3/Makefile.in b/source3/Makefile.in index eddcaaac42..ba8fde0fa1 100644 --- a/source3/Makefile.in +++ b/source3/Makefile.in @@ -984,7 +984,11 @@ REPLACETORT_OBJ = @libreplacedir@/test/testsuite.o \ NDRDUMP_OBJ = ../librpc/tools/ndrdump.o \ $(PARAM_OBJ) $(LIBNDR_GEN_OBJ) \ $(LIBSAMBA_OBJ) $(LIB_NONSMBD_OBJ) $(POPT_LIB_OBJ) \ - librpc/gen_ndr/ndr_svcctl.o + $(LIBNDR_DRSUAPI_OBJ) $(COMPRESSION_OBJ) \ + librpc/gen_ndr/ndr_svcctl.o \ + librpc/gen_ndr/tables.o ../librpc/ndr/ndr_table.o \ + ../librpc/ndr/ndr_krb5pac.o \ + librpc/gen_ndr/ndr_krb5pac.o DEBUG2HTML_OBJ = utils/debug2html.o utils/debugparse.o @@ -1217,6 +1221,10 @@ samba3-idl:: ../librpc/idl/ntsvcs.idl librpc/idl/libnetapi.idl ../librpc/idl/drsuapi.idl \ ../librpc/idl/drsblobs.idl ../librpc/idl/nbt.idl +librpc/gen_ndr/tables.c:: librpc/gen_ndr/*.h + @echo "Generating $@" + @$(PERL) ../librpc/tables.pl $^ > $@ + ##################################################################### @@ -1539,7 +1547,7 @@ bin/locktest2@EXEEXT@: $(BINARY_PREREQS) $(LOCKTEST2_OBJ) @BUILD_POPT@ @LIBTALLO bin/ndrdump@EXEEXT@: $(BINARY_PREREQS) $(NDRDUMP_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @LIBTDB_SHARED@ @echo Linking $@ @$(CC) $(FLAGS) -o $@ $(NDRDUMP_OBJ) $(DYNEXP) $(LDFLAGS) $(LIBS) \ - $(POPT_LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) + $(POPT_LIBS) $(LDAP_LIBS) $(LIBTALLOC_LIBS) $(LIBTDB_LIBS) $(ZLIB_LIBS) bin/debug2html@EXEEXT@: $(BINARY_PREREQS) $(DEBUG2HTML_OBJ) @BUILD_POPT@ @LIBTALLOC_SHARED@ @echo Linking $@ diff --git a/source3/librpc/gen_ndr/tables.c b/source3/librpc/gen_ndr/tables.c new file mode 100644 index 0000000000..f2064d95ac --- /dev/null +++ b/source3/librpc/gen_ndr/tables.c @@ -0,0 +1,83 @@ + +/* Automatically generated by tables.pl. DO NOT EDIT */ + +#include "includes.h" +#include "librpc/ndr/libndr.h" +#include "librpc/ndr/ndr_table.h" +#include "librpc/gen_ndr/ndr_dfs.h" +#include "librpc/gen_ndr/ndr_drsblobs.h" +#include "librpc/gen_ndr/ndr_drsuapi.h" +#include "librpc/gen_ndr/ndr_dssetup.h" +#include "librpc/gen_ndr/ndr_echo.h" +#include "librpc/gen_ndr/ndr_epmapper.h" +#include "librpc/gen_ndr/ndr_eventlog.h" +#include "librpc/gen_ndr/ndr_initshutdown.h" +#include "librpc/gen_ndr/ndr_krb5pac.h" +#include "librpc/gen_ndr/ndr_lsa.h" +#include "librpc/gen_ndr/ndr_netlogon.h" +#include "librpc/gen_ndr/ndr_ntsvcs.h" +#include "librpc/gen_ndr/ndr_samr.h" +#include "librpc/gen_ndr/ndr_srvsvc.h" +#include "librpc/gen_ndr/ndr_svcctl.h" +#include "librpc/gen_ndr/ndr_winreg.h" +#include "librpc/gen_ndr/ndr_wkssvc.h" + +NTSTATUS ndr_table_register_builtin_tables(void) +{ + NTSTATUS status; + + status = ndr_table_register(&ndr_table_netdfs); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_drsblobs); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_drsuapi); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_dssetup); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_rpcecho); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_epmapper); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_eventlog); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_initshutdown); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_krb5pac); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_lsarpc); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_netlogon); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_ntsvcs); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_samr); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_srvsvc); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_svcctl); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_winreg); + if (NT_STATUS_IS_ERR(status)) return status; + + status = ndr_table_register(&ndr_table_wkssvc); + if (NT_STATUS_IS_ERR(status)) return status; + + + + return NT_STATUS_OK; +} -- cgit