diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2005-08-21 23:17:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:34:17 -0500 |
commit | efc03df292aa84edb592c22191dbf86cdf8c32d0 (patch) | |
tree | 8a72f715ced0922effaa6dc48000bb1b48b82678 /source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm | |
parent | 6e388c27d86d77f2c7f9414fbb152c246ca53022 (diff) | |
download | samba-efc03df292aa84edb592c22191dbf86cdf8c32d0.tar.gz samba-efc03df292aa84edb592c22191dbf86cdf8c32d0.tar.bz2 samba-efc03df292aa84edb592c22191dbf86cdf8c32d0.zip |
r9459: Move pidl up one level (to prevent too much nesting)
(This used to be commit e48202275e60c18e464457d200daeb953386e221)
Diffstat (limited to 'source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm')
-rw-r--r-- | source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm b/source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm deleted file mode 100644 index 81c75705de..0000000000 --- a/source4/build/pidl/Parse/Pidl/Samba/EJSHeader.pm +++ /dev/null @@ -1,76 +0,0 @@ -################################################### -# create C header files for an EJS mapping functions -# Copyright tridge@samba.org 2005 -# released under the GNU GPL - -package Parse::Pidl::Samba::EJSHeader; - -use strict; -use Parse::Pidl::Typelist; -use Parse::Pidl::Util qw(has_property); - -my($res); - -sub pidl ($) -{ - $res .= shift; -} - -##################################################################### -# prototype a typedef -sub HeaderTypedefProto($) -{ - my $d = shift; - my $name = $d->{NAME}; - - return unless has_property($d, "public"); - - my $type_decl = Parse::Pidl::Typelist::mapType($name); - - pidl "NTSTATUS ejs_push_$d->{NAME}(struct ejs_rpc *, struct MprVar *, const char *, const $type_decl *);\n"; - pidl "NTSTATUS ejs_pull_$d->{NAME}(struct ejs_rpc *, struct MprVar *, const char *, $type_decl *);\n"; -} - -##################################################################### -# parse the interface definitions -sub HeaderInterface($) -{ - my($interface) = shift; - - my $count = 0; - - pidl "#ifndef _HEADER_EJS_$interface->{NAME}\n"; - pidl "#define _HEADER_EJS_$interface->{NAME}\n\n"; - - if (defined $interface->{PROPERTIES}->{depends}) { - my @d = split / /, $interface->{PROPERTIES}->{depends}; - foreach my $i (@d) { - pidl "#include \"librpc/gen_ndr/ndr_$i\_ejs\.h\"\n"; - } - } - - pidl "\n"; - - foreach my $d (@{$interface->{TYPEDEFS}}) { - HeaderTypedefProto($d); - } - - pidl "\n"; - pidl "#endif /* _HEADER_EJS_$interface->{NAME} */\n"; -} - -##################################################################### -# parse a parsed IDL into a C header -sub Parse($) -{ - my($idl) = shift; - - $res = ""; - pidl "/* header auto-generated by pidl */\n\n"; - foreach my $x (@{$idl}) { - ($x->{TYPE} eq "INTERFACE") && HeaderInterface($x); - } - return $res; -} - -1; |