From f1bd7620a304ad4ef9df427b8c6ddc140f4261ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Mayer?= Date: Sun, 18 Sep 2005 21:57:59 +0000 Subject: [PATCH] Update README.ethereal and sync with current samba tree svn path=/trunk/; revision=15859 --- tools/pidl/README.ethereal | 28 +++++- tools/pidl/lib/Parse/Pidl/IDL.pm | 126 ++++++++++++------------- tools/pidl/lib/Parse/Pidl/Samba/TDR.pm | 3 +- tools/pidl/pm_to_blib | 0 4 files changed, 87 insertions(+), 70 deletions(-) delete mode 100644 tools/pidl/pm_to_blib diff --git a/tools/pidl/README.ethereal b/tools/pidl/README.ethereal index 55ae957933..a3638c3432 100644 --- a/tools/pidl/README.ethereal +++ b/tools/pidl/README.ethereal @@ -1,14 +1,32 @@ +The REAMDE specific to the Ethereal copy of the pidl sources +============================================================ + This tree is a convenience copy of svn://svnanon.samba.org/samba/branches/SAMBA_4_0/source/pidl to allow building Ethereal pidl dissectors without having to -access a remove svn repository. +access a remote svn repository. -Don't do changes here, do them at the samba tree! +Don't do changes here, do them at the samba tree! Changes to this tree will +be overwritten the next time the sources from the samba tree are synced. In order to build, install yapp (on Suse, the rpm is named perl-Parse-Yapp), then do -make Makefile.PL && make +make Makefile.PL && make && make doc && make install -run +Note: This will not install the manpage (pidl.1). If you know how to do that +please send the info to ethereal-dev@ethereal.com +Note2: In order for "make doc" to succeed, you will need + a) xsltproc and + b) Internet access or a proper redirect to local copies of the manpages/docbook.xsl + and html/docbook.xsl files. + +run pidl with: + +pidl --eth-parser -- (don't forget the "--") + +This *will* result in a warning like: +atsvc.idl:5:23: idl_types.h: No such file or directory +and *may* result in additional warnings like: +Warning: No conformance file `initshutdown.cnf' +Unable to handle string with flags STR_LEN4|STR_NOTERM at /usr/lib/perl5/site_perl/5.8.6/Parse/Pidl/Ethereal/NDR.pm line 283. -blib/pidl --eth-parser -- diff --git a/tools/pidl/lib/Parse/Pidl/IDL.pm b/tools/pidl/lib/Parse/Pidl/IDL.pm index d13e115a33..1aa4426cd6 100644 --- a/tools/pidl/lib/Parse/Pidl/IDL.pm +++ b/tools/pidl/lib/Parse/Pidl/IDL.pm @@ -2101,19 +2101,19 @@ sub new { [#Rule 2 'idl', 2, sub -#line 19 "idl.yp" +#line 19 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 3 'idl', 2, sub -#line 20 "idl.yp" +#line 20 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 4 'coclass', 7, sub -#line 24 "idl.yp" +#line 24 "pidl/idl.yp" {$_[3] => { "TYPE" => "COCLASS", "PROPERTIES" => $_[1], @@ -2129,13 +2129,13 @@ sub [#Rule 6 'interface_names', 4, sub -#line 36 "idl.yp" +#line 36 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 7 'interface', 8, sub -#line 40 "idl.yp" +#line 40 "pidl/idl.yp" {$_[3] => { "TYPE" => "INTERFACE", "PROPERTIES" => $_[1], @@ -2152,19 +2152,19 @@ sub [#Rule 9 'base_interface', 2, sub -#line 53 "idl.yp" +#line 53 "pidl/idl.yp" { $_[2] } ], [#Rule 10 'definitions', 1, sub -#line 57 "idl.yp" +#line 57 "pidl/idl.yp" { [ $_[1] ] } ], [#Rule 11 'definitions', 2, sub -#line 58 "idl.yp" +#line 58 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 12 @@ -2185,7 +2185,7 @@ sub [#Rule 17 'const', 6, sub -#line 66 "idl.yp" +#line 66 "pidl/idl.yp" {{ "TYPE" => "CONST", "DTYPE" => $_[2], @@ -2198,7 +2198,7 @@ sub [#Rule 18 'const', 7, sub -#line 75 "idl.yp" +#line 75 "pidl/idl.yp" {{ "TYPE" => "CONST", "DTYPE" => $_[2], @@ -2212,7 +2212,7 @@ sub [#Rule 19 'function', 7, sub -#line 88 "idl.yp" +#line 88 "pidl/idl.yp" {{ "TYPE" => "FUNCTION", "NAME" => $_[3], @@ -2226,7 +2226,7 @@ sub [#Rule 20 'declare', 5, sub -#line 100 "idl.yp" +#line 100 "pidl/idl.yp" {{ "TYPE" => "DECLARE", "PROPERTIES" => $_[2], @@ -2245,7 +2245,7 @@ sub [#Rule 23 'decl_enum', 1, sub -#line 114 "idl.yp" +#line 114 "pidl/idl.yp" {{ "TYPE" => "ENUM" }} @@ -2253,7 +2253,7 @@ sub [#Rule 24 'decl_bitmap', 1, sub -#line 120 "idl.yp" +#line 120 "pidl/idl.yp" {{ "TYPE" => "BITMAP" }} @@ -2261,7 +2261,7 @@ sub [#Rule 25 'typedef', 6, sub -#line 126 "idl.yp" +#line 126 "pidl/idl.yp" {{ "TYPE" => "TYPEDEF", "PROPERTIES" => $_[2], @@ -2287,7 +2287,7 @@ sub [#Rule 30 'typedecl', 2, sub -#line 139 "idl.yp" +#line 139 "pidl/idl.yp" { $_[1] } ], [#Rule 31 @@ -2299,13 +2299,13 @@ sub [#Rule 33 'type', 1, sub -#line 142 "idl.yp" +#line 142 "pidl/idl.yp" { "void" } ], [#Rule 34 'enum', 5, sub -#line 146 "idl.yp" +#line 146 "pidl/idl.yp" {{ "TYPE" => "ENUM", "NAME" => $_[2], @@ -2315,13 +2315,13 @@ sub [#Rule 35 'enum_elements', 1, sub -#line 154 "idl.yp" +#line 154 "pidl/idl.yp" { [ $_[1] ] } ], [#Rule 36 'enum_elements', 3, sub -#line 155 "idl.yp" +#line 155 "pidl/idl.yp" { push(@{$_[1]}, $_[3]); $_[1] } ], [#Rule 37 @@ -2330,13 +2330,13 @@ sub [#Rule 38 'enum_element', 3, sub -#line 159 "idl.yp" +#line 159 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 39 'bitmap', 5, sub -#line 163 "idl.yp" +#line 163 "pidl/idl.yp" {{ "TYPE" => "BITMAP", "NAME" => $_[2], @@ -2346,25 +2346,25 @@ sub [#Rule 40 'bitmap_elements', 1, sub -#line 171 "idl.yp" +#line 171 "pidl/idl.yp" { [ $_[1] ] } ], [#Rule 41 'bitmap_elements', 3, sub -#line 172 "idl.yp" +#line 172 "pidl/idl.yp" { push(@{$_[1]}, $_[3]); $_[1] } ], [#Rule 42 'bitmap_element', 3, sub -#line 175 "idl.yp" +#line 175 "pidl/idl.yp" { "$_[1] ( $_[3] )" } ], [#Rule 43 'struct', 5, sub -#line 179 "idl.yp" +#line 179 "pidl/idl.yp" {{ "TYPE" => "STRUCT", "NAME" => $_[2], @@ -2374,7 +2374,7 @@ sub [#Rule 44 'empty_element', 2, sub -#line 187 "idl.yp" +#line 187 "pidl/idl.yp" {{ "NAME" => "", "TYPE" => "EMPTY", @@ -2394,7 +2394,7 @@ sub [#Rule 47 'optional_base_element', 2, sub -#line 201 "idl.yp" +#line 201 "pidl/idl.yp" { $_[2]->{PROPERTIES} = Parse::Pidl::Util::FlattenHash([$_[1],$_[2]->{PROPERTIES}]); $_[2] } ], [#Rule 48 @@ -2403,13 +2403,13 @@ sub [#Rule 49 'union_elements', 2, sub -#line 206 "idl.yp" +#line 206 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 50 'union', 5, sub -#line 210 "idl.yp" +#line 210 "pidl/idl.yp" {{ "TYPE" => "UNION", "NAME" => $_[2], @@ -2419,7 +2419,7 @@ sub [#Rule 51 'base_element', 5, sub -#line 218 "idl.yp" +#line 218 "pidl/idl.yp" {{ "NAME" => $_[4], "TYPE" => $_[2], @@ -2433,13 +2433,13 @@ sub [#Rule 52 'pointers', 0, sub -#line 232 "idl.yp" +#line 232 "pidl/idl.yp" { 0 } ], [#Rule 53 'pointers', 2, sub -#line 233 "idl.yp" +#line 233 "pidl/idl.yp" { $_[1]+1 } ], [#Rule 54 @@ -2448,7 +2448,7 @@ sub [#Rule 55 'element_list1', 3, sub -#line 238 "idl.yp" +#line 238 "pidl/idl.yp" { push(@{$_[1]}, $_[2]); $_[1] } ], [#Rule 56 @@ -2460,13 +2460,13 @@ sub [#Rule 58 'element_list2', 1, sub -#line 244 "idl.yp" +#line 244 "pidl/idl.yp" { [ $_[1] ] } ], [#Rule 59 'element_list2', 3, sub -#line 245 "idl.yp" +#line 245 "pidl/idl.yp" { push(@{$_[1]}, $_[3]); $_[1] } ], [#Rule 60 @@ -2475,13 +2475,13 @@ sub [#Rule 61 'array_len', 3, sub -#line 250 "idl.yp" +#line 250 "pidl/idl.yp" { push(@{$_[3]}, "*"); $_[3] } ], [#Rule 62 'array_len', 4, sub -#line 251 "idl.yp" +#line 251 "pidl/idl.yp" { push(@{$_[4]}, "$_[2]"); $_[4] } ], [#Rule 63 @@ -2490,31 +2490,31 @@ sub [#Rule 64 'property_list', 4, sub -#line 257 "idl.yp" +#line 257 "pidl/idl.yp" { Parse::Pidl::Util::FlattenHash([$_[1],$_[3]]); } ], [#Rule 65 'properties', 1, sub -#line 260 "idl.yp" +#line 260 "pidl/idl.yp" { $_[1] } ], [#Rule 66 'properties', 3, sub -#line 261 "idl.yp" +#line 261 "pidl/idl.yp" { Parse::Pidl::Util::FlattenHash([$_[1], $_[3]]); } ], [#Rule 67 'property', 1, sub -#line 264 "idl.yp" +#line 264 "pidl/idl.yp" {{ "$_[1]" => "1" }} ], [#Rule 68 'property', 4, sub -#line 265 "idl.yp" +#line 265 "pidl/idl.yp" {{ "$_[1]" => "$_[3]" }} ], [#Rule 69 @@ -2523,7 +2523,7 @@ sub [#Rule 70 'listtext', 3, sub -#line 270 "idl.yp" +#line 270 "pidl/idl.yp" { "$_[1] $_[3]" } ], [#Rule 71 @@ -2532,13 +2532,13 @@ sub [#Rule 72 'commalisttext', 3, sub -#line 275 "idl.yp" +#line 275 "pidl/idl.yp" { "$_[1],$_[3]" } ], [#Rule 73 'anytext', 0, sub -#line 279 "idl.yp" +#line 279 "pidl/idl.yp" { "" } ], [#Rule 74 @@ -2553,91 +2553,91 @@ sub [#Rule 77 'anytext', 3, sub -#line 281 "idl.yp" +#line 281 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 78 'anytext', 3, sub -#line 282 "idl.yp" +#line 282 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 79 'anytext', 3, sub -#line 283 "idl.yp" +#line 283 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 80 'anytext', 3, sub -#line 284 "idl.yp" +#line 284 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 81 'anytext', 3, sub -#line 285 "idl.yp" +#line 285 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 82 'anytext', 3, sub -#line 286 "idl.yp" +#line 286 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 83 'anytext', 3, sub -#line 287 "idl.yp" +#line 287 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 84 'anytext', 3, sub -#line 288 "idl.yp" +#line 288 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 85 'anytext', 3, sub -#line 289 "idl.yp" +#line 289 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 86 'anytext', 3, sub -#line 290 "idl.yp" +#line 290 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 87 'anytext', 3, sub -#line 291 "idl.yp" +#line 291 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 88 'anytext', 3, sub -#line 292 "idl.yp" +#line 292 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 89 'anytext', 3, sub -#line 293 "idl.yp" +#line 293 "pidl/idl.yp" { "$_[1]$_[2]$_[3]" } ], [#Rule 90 'anytext', 5, sub -#line 294 "idl.yp" +#line 294 "pidl/idl.yp" { "$_[1]$_[2]$_[3]$_[4]$_[5]" } ], [#Rule 91 'anytext', 5, sub -#line 295 "idl.yp" +#line 295 "pidl/idl.yp" { "$_[1]$_[2]$_[3]$_[4]$_[5]" } ], [#Rule 92 @@ -2655,7 +2655,7 @@ sub [#Rule 96 'text', 1, sub -#line 309 "idl.yp" +#line 309 "pidl/idl.yp" { "\"$_[1]\"" } ], [#Rule 97 @@ -2669,7 +2669,7 @@ sub bless($self,$class); } -#line 320 "idl.yp" +#line 320 "pidl/idl.yp" use Parse::Pidl::Util; diff --git a/tools/pidl/lib/Parse/Pidl/Samba/TDR.pm b/tools/pidl/lib/Parse/Pidl/Samba/TDR.pm index 9bcf7f1a77..124cb61bb4 100644 --- a/tools/pidl/lib/Parse/Pidl/Samba/TDR.pm +++ b/tools/pidl/lib/Parse/Pidl/Samba/TDR.pm @@ -5,7 +5,6 @@ package Parse::Pidl::Samba::TDR; use Parse::Pidl::Util qw(has_property ParseExpr is_constant); -use Data::Dumper; use strict; @@ -201,7 +200,7 @@ sub ParserTypedef($$) { STRUCT => \&ParserStruct, UNION => \&ParserUnion, ENUM => \&ParserEnum, BITMAP => \&ParserBitmap - }->{$e->{DATA}->{TYPE}}($e->{DATA}, $e->{NAME}, $t, has_property($e, "public")); + }->{$e->{DATA}->{TYPE}}->($e->{DATA}, $e->{NAME}, $t, has_property($e, "public")); pidl ""; } diff --git a/tools/pidl/pm_to_blib b/tools/pidl/pm_to_blib deleted file mode 100644 index e69de29bb2..0000000000