then put the paths yourself into PERL5LIB. Then you don't need to cd to any directory at all. Nor do you need to run "./Build" or make or any other harness.

Why would the caller need to know anything about the internals of the script to run it? Again, this is not a solution.

Compensating for the hardcoded @INC by putting "use lib" all over test scripts raises separation of concern issues.

No, you don't need to add any use lib for it to work. Saying it 5 times doesn't make it true.

M:B manages to provide a 100% portable way to put such files in a distro subdir of the distro-writer's choosing.

So does M::M. The same mechanism, in fact.

propose a solution that [...] ensures that files meant for build/test but not runtime never leave the distro.

I didn't know that was a problem.

propose a solution that uses ExtUtils::MakeMaker to run make file commands, doesn't interfere with M:B, is 100% portable, respects separation of concerns (no confusing operational code with the configuration needs of a specific environment), and ensures that files meant for build/test but not runtime never leave the distro.

Quite demanding from someone who states that it's ok to require intimate knowledge of the distro's file layout to run a test script.


In reply to Re^7: Do Pure Perl CPAN packages really need to use ExtUtils::Command::MM? by ikegami
in thread Do Pure Perl CPAN packages really need to use ExtUtils::Command::MM? by ELISHEVA

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.