bikeNomad mentioned PREREQ_PM, but nobody else mentioned h2xs, so I will. Read the perdocs on h2xs, create a skelton module with h2xs (probably with the -A and -X options), and edit it accordingly, like the PREREQ_PM in Makefile.PL. Also look at the perldocs at ExtUtils::MakeMaker (the EXE_FILES arrayref argument is probably what you want). Then look at what other people do in their modules. If the WriteMakefile in Makefile.PL fails, you could kick off the CPAN module to install the necessary modules.

Update: Hmm, WriteMakefile() warns you if modules in PREREQ_PM are not present, but it doesn't set any flag or return failure or anything. There's some commented out code in MakeMaker.pm that seems like there was some attempt to autoinstall via the CPAN module any missing modules, but I wonder why its not implemented. It would have been a nice option. You could still try to roll your own in the Makefile.PL, though.


In reply to Re: How can I create a Bundle quickly and easily? by runrig
in thread How can I create a Bundle quickly and easily? by snafu

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.