Grokbase
Topics Posts Groups | in
x
[ help ]

Steve Hay (stev...@uk.radan.com)

Profile | Posts (1859)

User Information

Display Name:Steve Hay
Partial Email Address:stev...@uk.radan.com
Posts:
1859 total
9 in mod_perl
42 in PAR
1811 in Perl 5 Porters

5 Most Recent

All Posts
1) Steve Hay Re: Module-ScanDeps-0.75 broken?
| +1 vote
Grr. That fixes the scandeps program output, but doesn't fix my PAR problem because...
PAR
[ Profile | Reply to group ] [ Flat  Thread  Threaded ]
Steve Hay wrote:
> Note that the foreach-loop in question is precisely the new part of
> ScanDeps.pm that I originally said was what breaks 0.75 for me. It looks
> like that loop should have been added after the scan_deps_static() call
> rather than before it.

Grr. That fixes the scandeps program output, but doesn't fix my PAR
problem because PAR::Packer::pack_manifest_hash() directly calls
Module::ScanDeps::add_deps() later on (line 739 of VERSION 0.975). It is
*that* call which actually adds Decrypt.dll to the PAR package, and once
again that call is screwed up if the foreach-loop in
Module::ScanDeps::scan_deps() has been run earlier.

--
2) Steve Hay Re: Module-ScanDeps-0.75 broken?
| +1 vote
Putting some debug into add_deps() was more revealing. With the attached "debug" patch applied, the...
PAR
[ Profile | Reply to group ] [ Flat  Thread  Threaded ]
Steffen Mueller wrote:
> I would suggest putting a debug statement into _add_info to see what
> happens to DBI.*.

Putting some debug into add_deps() was more revealing. With the attached
"debug" patch applied, the output from "scandeps -V
C:\perl5\site\lib\DBI.pm" begins like this:

$rv->{Carp.pm} DOES NOT EXIST
$rv->{DynaLoader.pm} DOES NOT EXIST
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/autosplit.ix
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_expandspec.al
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_findfile.al
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_find_symbol_anywhere.al
$rv->{Exporter.pm} DOES NOT EXIST
$rv->{DBI/PurePerl.pm} DOES NOT EXIST
$rv->{Exporter.pm} EXISTS--WON'T LOOK IN auto/ !
$rv->{strict.pm} DOES NOT EXIST
$rv->{strict.pm} EXISTS--WON'T LOOK IN auto/ !
$rv->{DBI.pm} EXISTS--WON'T LOOK IN auto/ !

You can see that it's decided not to look into auto/DBI because DBI.pm
already has an entry in some hash. It appears that the hash entry in
question got put there by the "foreach my $input_file (@{$args{files}})
{ ... }" loop in scan_deps(). If I move that loop after the
scan_deps_static() call, which is where add_deps() gets called from, (as
per the attached "fix" patch) then the output now begins:

$rv->{Carp.pm} DOES NOT EXIST
$rv->{DynaLoader.pm} DOES NOT EXIST
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/autosplit.ix
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_expandspec.al
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_findfile.al
ADDING INFO FOR C:/perl5/lib/auto/DynaLoader/dl_find_symbol_anywhere.al
$rv->{Exporter.pm} DOES NOT EXIST
$rv->{DBI/PurePerl.pm} DOES NOT EXIST
$rv->{Exporter.pm} EXISTS--WON'T LOOK IN auto/ !
$rv->{strict.pm} DOES NOT EXIST
$rv->{strict.pm} EXISTS--WON'T LOOK IN auto/ !
$rv->{DBI.pm} DOES NOT EXIST
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/dbd_xsh.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBI.bs
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBI.dll
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBI.exp
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBI.ilk
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBI.pdb
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/dbipport.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/dbivport.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/DBIXS.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/dbixs_rev.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/dbi_sql.h
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/Driver.xst
ADDING INFO FOR C:/perl5/site/lib/auto/DBI/Driver_xst.h

and the bug appears to be fixed: DBI.dll gets included in the output.

Note that the foreach-loop in question is precisely the new part of
ScanDeps.pm that I originally said was what breaks 0.75 for me. It looks
like that loop should have been added after the scan_deps_static() call
rather than before it.

-- --- ScanDeps.pm.orig 2007-06-24 18:15:48.000000000 +0100
+++ ScanDeps.pm 2007-07-18 12:48:10.589473100 +0100
@@ -484,6 +484,8 @@
$args{keys} = [map {path_to_inc_name($_, $args{warn_missing})} @{$args{files}}]
     }

+    scan_deps_static(\%args);
+
     my ($type, $path);
     foreach my $input_file (@{$args{files}}) {
         $type = 'module';
@@ -492,8 +494,6 @@
_add_info($args{rv}, path_to_inc_name($path, $args{warn_missing}), $path, undef, $type);
     }

-    scan_deps_static(\%args);
-
     if ($args{execute} or $args{compile}) {
         scan_deps_runtime(
             rv      => $args{rv},
@@ -805,9 +805,13 @@
           or _warn_of_missing_module($module, $args{warn_missing}), next;

         if (exists $rv->{$module}) {
+            print STDERR "\$rv->{$module} EXISTS--WON'T LOOK IN auto/ !\n";
             _add_info($rv, $module, $file, $used_by, undef);
             next;
         }
+        else {
+            print STDERR "\$rv->{$module} DOES NOT EXIST\n";
+        }

         my $type = 'module';
         $type = 'data' unless $file =~ /\.p[mh]$/i;
@@ -825,6 +829,7 @@
                 $type = 'autoload' if $ext eq '.ix' or $ext eq '.al';
                 $type ||= 'data';

+                print STDERR "ADDING INFO FOR $_->{file}\n";
_add_info($rv, "auto/$path/$_->{name}", $_->{file}, $module,
                     $type);
             } --- ScanDeps.pm.orig 2007-06-24 18:15:48.000000000 +0100
+++ ScanDeps.pm 2007-07-18 12:48:02.417431100 +0100
@@ -805,9 +805,13 @@
           or _warn_of_missing_module($module, $args{warn_missing}), next;

         if (exists $rv->{$module}) {
+            print STDERR "\$rv->{$module} EXISTS--WON'T LOOK IN auto/ !\n";
             _add_info($rv, $module, $file, $used_by, undef);
             next;
         }
+        else {
+            print STDERR "\$rv->{$module} DOES NOT EXIST\n";
+        }

         my $type = 'module';
         $type = 'data' unless $file =~ /\.p[mh]$/i;
@@ -825,6 +829,7 @@
                 $type = 'autoload' if $ext eq '.ix' or $ext eq '.al';
                 $type ||= 'data';

+                print STDERR "ADDING INFO FOR $_->{file}\n";
_add_info($rv, "auto/$path/$_->{name}", $_->{file}, $module,
                     $type);
             }
3) Steve Hay Re: Module-ScanDeps-0.75 broken?
| +1 vote
You can install Filter-Crypto with a DEBUGGING perl by specifying the --debug-mode option to...
PAR
[ Profile | Reply to group ] [ Flat  Thread  Threaded ]
Steffen Mueller wrote:
> Steve Hay schrieb:
>> I've had a report from a non-Win32 user of Filter-Crypto who experienced
>> exactly the same problem that I originally had. I pointed out that
>> downgrading Module-ScanDeps to 0.73 might fix his problem, and he
>> confirmed that it did. See the CPAN/RT ticket here:
>>
>> http://rt.cpan.org/Public/Bug/Display.html?id=28101
>>
>> That was on RedHat Enterprise Linux 3.0, and the same on Solaris 8 (Sparc).
>>
>> So it's not just Win32. Are you able to try Filter-Crypto yourself on
>> whatever OS you have? Perhaps that goes wrong on any OS, while some
>> other modules work in general but not on Win32?
>
> It's more likely that I can use Filter::Crypto than that I can get a
> win32 soon. The perl on my work PC is built with DEBUGGING, so I can't
> install it there. I'll either have to build my own perl or do it
> somewhere else. I guess this has to be postponed for lack of time.

You can install Filter-Crypto with a DEBUGGING perl by specifying the
--debug-mode option to Makefile.PL.

This causes it to output lots of debug information showing you the data
getting encrypted/decrypted (which in turn causes a couple of the tests
to fail due to unexpected output), but otherwise it should work as usual.

--
4) Steve Hay Re: Module-ScanDeps-0.75 broken?
| +1 vote
Better late than never ;-) I've had a report from a non-Win32 user of Filter-Crypto who experienced...
PAR
[ Profile | Reply to group ] [ Flat  Thread  Threaded ]
Steffen Mueller wrote:
> Hi Steve,
>
> sorry for replying so late.

Better late than never ;-)


[snip useful insights which I'll look at later...]

>
> I don't have *any* win32 any more, so I can't do actual bug hunting and
> my head isn't so great at executing Perl code :(

I've had a report from a non-Win32 user of Filter-Crypto who experienced
exactly the same problem that I originally had. I pointed out that
downgrading Module-ScanDeps to 0.73 might fix his problem, and he
confirmed that it did. See the CPAN/RT ticket here:

http://rt.cpan.org/Public/Bug/Display.html?id=28101

That was on RedHat Enterprise Linux 3.0, and the same on Solaris 8 (Sparc).

So it's not just Win32. Are you able to try Filter-Crypto yourself on
whatever OS you have? Perhaps that goes wrong on any OS, while some
other modules work in general but not on Win32?

--
5) Steve Hay Re: Module-ScanDeps-0.75 broken?
| +1 vote
Still no luck. That finds Digest/MD5.pm but not the DLL. Same again with other simple modules like...
PAR
[ Profile | Reply to group ] [ Flat  Thread  Threaded ]
Roderich Schupp wrote:
> On 7/4/07, Steve Hay <steve.hay@uk.radan.com> wrote:
>> This in turn seems to be due a problem in Module-ScanDeps. I'm using
>> version 0.75, and I find that the output of
>>
>> scandeps -V C:\perl5\site\lib\DBI.pm
>>
>> mentions DBI.pm but not DBI.dll. If I try the same command using version
>> 0.54 of Module-ScanDeps then DBI.dll is mentioned in the output too.
>
> FWIW, Module::ScanDeps 0.75 works as expected here on Linux,
> so it must be something specific to Windows. You might try a
> simpler example, say Digest::MD5.

Still no luck. That finds Digest/MD5.pm but not the DLL. Same again with
other simple modules like Cwd and Fcntl...

--

spacer
Profile | Posts (1859)
Home > People > Steve Hay