svn commit: samba r14361 - in branches/SAMBA_4_0/source: . include librpc/idl pidl/lib/Parse/Pidl pidl/lib/Parse/Pidl/Samba4/NDR

jelmer at samba.org jelmer at samba.org
Tue Mar 14 00:13:03 GMT 2006


Author: jelmer
Date: 2006-03-14 00:12:58 +0000 (Tue, 14 Mar 2006)
New Revision: 14361

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=14361

Log:
Support 'helper' attribute in pidl and use it.
Remove some headers from include/includes.h (they're now only included 
in the file they are used)

Modified:
   branches/SAMBA_4_0/source/include/includes.h
   branches/SAMBA_4_0/source/librpc/idl/drsuapi.idl
   branches/SAMBA_4_0/source/librpc/idl/krb5pac.idl
   branches/SAMBA_4_0/source/librpc/idl/nbt.idl
   branches/SAMBA_4_0/source/librpc/idl/security.idl
   branches/SAMBA_4_0/source/librpc/idl/spoolss.idl
   branches/SAMBA_4_0/source/main.mk
   branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm
   branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm


Changeset:
Modified: branches/SAMBA_4_0/source/include/includes.h
===================================================================
--- branches/SAMBA_4_0/source/include/includes.h	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/include/includes.h	2006-03-14 00:12:58 UTC (rev 14361)
@@ -125,14 +125,7 @@
 #include "libcli/nbt/libnbt.h"
 #include "libcli/util/proto.h"
 
-/* These headers are used by the NDR parsers. They are globally 
- * included at the moment, but will be included by the autogenerated 
- * NDR parsers later on and removed from here. */
-#include "libcli/nbt/nbtname.h"
-#include "librpc/ndr/ndr_sec.h"
-#include "librpc/ndr/ndr_drsuapi.h"
-#include "librpc/ndr/ndr_spoolss_buf.h"
-#include "librpc/ndr/ndr_krb5pac.h"
+/* FIXME: This header should be included by pidl where necessary */
 #include "librpc/ndr/ndr_compression.h"
 
 #undef _PRINTF_ATTRIBUTE

Modified: branches/SAMBA_4_0/source/librpc/idl/drsuapi.idl
===================================================================
--- branches/SAMBA_4_0/source/librpc/idl/drsuapi.idl	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/librpc/idl/drsuapi.idl	2006-03-14 00:12:58 UTC (rev 14361)
@@ -7,7 +7,8 @@
   authservice("ldap"),
   helpstring("Active Directory Replication"),
   pointer_default(unique),
-  depends(security)
+  depends(security),
+  helper("librpc/ndr/ndr_drsuapi.h")
 ] 
 interface drsuapi
 {

Modified: branches/SAMBA_4_0/source/librpc/idl/krb5pac.idl
===================================================================
--- branches/SAMBA_4_0/source/librpc/idl/krb5pac.idl	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/librpc/idl/krb5pac.idl	2006-03-14 00:12:58 UTC (rev 14361)
@@ -7,7 +7,8 @@
 [
   version(0.0),
   pointer_default(unique),
-  depends(security,netlogon)
+  depends(security,netlogon),
+  helper("librpc/ndr/ndr_krb5pac.h")
 ]
 interface krb5pac
 {

Modified: branches/SAMBA_4_0/source/librpc/idl/nbt.idl
===================================================================
--- branches/SAMBA_4_0/source/librpc/idl/nbt.idl	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/librpc/idl/nbt.idl	2006-03-14 00:12:58 UTC (rev 14361)
@@ -9,7 +9,8 @@
 */
 
 [
-  depends(security,svcctl)
+  depends(security,svcctl),
+  helper("libcli/nbt/nbtname.h")
 ] interface nbt
 {
 	const int NBT_NAME_SERVICE_PORT  = 137;

Modified: branches/SAMBA_4_0/source/librpc/idl/security.idl
===================================================================
--- branches/SAMBA_4_0/source/librpc/idl/security.idl	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/librpc/idl/security.idl	2006-03-14 00:12:58 UTC (rev 14361)
@@ -6,7 +6,8 @@
 
 [
 	pointer_default(unique),
-	depends(misc)
+	depends(misc),
+	helper("librpc/ndr/ndr_sec.h")
 ]
 interface security
 {

Modified: branches/SAMBA_4_0/source/librpc/idl/spoolss.idl
===================================================================
--- branches/SAMBA_4_0/source/librpc/idl/spoolss.idl	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/librpc/idl/spoolss.idl	2006-03-14 00:12:58 UTC (rev 14361)
@@ -10,7 +10,8 @@
   pointer_default(unique),
   pointer_default_top(unique),
   helpstring("Spooler SubSystem"),
-  depends(security)
+  depends(security),
+  helper("librpc/ndr/ndr_spoolss_buf.h")
 ] interface spoolss
 {
 	typedef struct {

Modified: branches/SAMBA_4_0/source/main.mk
===================================================================
--- branches/SAMBA_4_0/source/main.mk	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/main.mk	2006-03-14 00:12:58 UTC (rev 14361)
@@ -236,11 +236,6 @@
 		param/param.h \
 		libcli/util/proto.h \
 		librpc/ndr/ndr_orpc_proto.h \
-		libcli/nbt/nbtname.h \
-		librpc/ndr/ndr_sec.h \
-		librpc/ndr/ndr_drsuapi.h \
-		librpc/ndr/ndr_spoolss_buf.h \
-		librpc/ndr/ndr_krb5pac.h \
 		librpc/ndr/ndr_compression.h
 
 clean_pch: 

Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm
===================================================================
--- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/NDR.pm	2006-03-14 00:12:58 UTC (rev 14361)
@@ -750,6 +750,7 @@
 	"pointer_default"	=> ["INTERFACE"],
 	"pointer_default_top"	=> ["INTERFACE"],
 	"depends"		=> ["INTERFACE"],
+	"helper"		=> ["INTERFACE"],
 	"authservice"		=> ["INTERFACE"],
 
 	# dcom

Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm
===================================================================
--- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm	2006-03-13 23:59:03 UTC (rev 14360)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm	2006-03-14 00:12:58 UTC (rev 14361)
@@ -2244,6 +2244,12 @@
 		}
 	}
 
+	if (defined $interface->{PROPERTIES}->{helper}) {
+		foreach (split / /, $interface->{PROPERTIES}->{helper}) {
+			pidl_hdr "#include $_";
+		}
+	}
+
 	if (defined $interface->{PROPERTIES}->{uuid}) {
 		my $name = uc $interface->{NAME};
 		pidl_hdr "#define DCERPC_$name\_UUID " . 



More information about the samba-cvs mailing list