Ronny wrote:

> I have a problem regarding PAR and Tk::DropSite. I've 
> compiled the sample script shown below, but the executable 
> won't run. I get no messages. The executable quits silently.

The problem is in Tk/DragDrop/Common.pm. It require's other
modules in Tk/DragDrop/ at run time with computed modules names.
This eludes Module::ScanDeps which is called
by pp to deduce all modules called directly and indirectly
by your script (by static analysis of the source).

You can either call pp with the -x option (which will run
your script once during pp'ing) so that these dynamic module
dependencies get picked up. But that's fragile, because
on-demand loading of modules might pick up different modules
depending on how you interact with your script while it's
run by pp. This holds esp. for anything Tk.

Or you can apply the following patch to Module::ScanDeps 0.51
which teaches it to preload everything below Tk/DragDrop/
once it encounters Tk/DragDrop/Common.pm.
Don't forget to re-pp after installing the patch.

Cheers, Roderich

--- Module/ScanDeps.pm.orig     2005-05-19 13:36:11.000000000 +0200
+++ Module/ScanDeps.pm  2005-05-19 13:49:59.000000000 +0200
@@ -295,6 +295,9 @@
     'Tk/Balloon.pm'     => [qw( Tk/balArrow.xbm )],
     'Tk/BrowseEntry.pm' => [qw( Tk/cbxarrow.xbm Tk/arrowdownwin.xbm )],
     'Tk/ColorEditor.pm' => [qw( Tk/ColorEdit.xpm )],
+    'Tk/DragDrop/Common.pm' => sub {
+        _glob_in_inc('Tk/DragDrop', 1);
+    },
     'Tk/FBox.pm'        => [qw( Tk/folder.xpm Tk/file.xpm )],
     'Tk/Toplevel.pm'    => [qw( Tk/Wm.pm )],
     'URI.pm'            => sub {

Reply via email to