|There's more than one way to do things|
Re^6: Do Pure Perl CPAN packages really need to use ExtUtils::Command::MM?by ELISHEVA (Prior)
|on Feb 24, 2011 at 23:52 UTC||Need Help??|
Sadly, despite all this back and forth I still don't get your point.
Because having to use bash -c'cd .. ; ./Build test' to run a single test is not right.
M:B lets the distro writer put custom paths in @INC to make the automated build-test-install cycle run more smoothly. You are not an automaton. If you don't want to take advantage of the fact that M:B automatically puts the right paths into @INC, 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.
If your script wasn't buggy in the first place...
This is post is not about buggy scripts and never has been. The issue at hand is how to configure M:M so that files that are needed for testing/building are available in @INC but don't end up getting installed at runtime.
M:B manages to provide a 100% portable way to put such files in a distro subdir of the distro-writer's choosing. It ensures that they will be available for test/build but does not install them to system/site directories after testing is complete. They stay put in the distro.
M:M is very rigid about how to handle such modules and it forces programmers into what I consider problematic or questionable practices:
If you really want to be helpful, 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.