Hello all,

here comes the next incarnation of the ModuleFinder I'm trying to build.
I'd love to hear your comments and bug reports.

For those who didn't got the last messages:
ModuleFinder collects all possible modules a script/module will need
at runtime. This is done by searching "use" and "require" lines. The
result is needed to build MacPerl standalone applications. All modules
are put into the resource fork of such a program.

Older versions replaced "require" with "use" and eval-ed this statement.
By watching %INC one checks whether new modules are added. This was
hard to understand and I rebuilt the algorithm to go through each line
of used/required modules myself.

You can test by saving "ModuleFinder.pl" as droplet and dropping files
onto it or by running "run-ModuleFinder.pl" and entering arguments.
Possible arguments are file paths to source scripts or library modules
like "IO::Socket". I should run under Unix as well.

There will be lots of cases when ModuleFinder can't process a line. This
is because a "require" lines can be arbitrarily complicated, e.g.
  require "File/Spec/$module.pm";
Here it is impossible to know the value of $module during compilation.
  $s = qq(
  blah blah use this and that
  )
I'm not checking multiline strings.


(hope the attachement gets through)


Best regards,
Axel.

-- 
(signature intentionally left blank)

Attachment: %ModuleFinder011105.sit
Description: application/applefile

Attachment: ModuleFinder011105.sit
Description: Binary data

Reply via email to