Why do you want Module::Build? Module::Install makes everything trivial.<br><br><div style="margin-left: 40px;">use inc::Module::Install;<br>install_script 'bin/foo';<br>install_share;<br></div><br>File::ShareDir finds files under share/ after they are installed.<br>
<br><div class="gmail_quote">On Sun, Nov 28, 2010 at 12:21 PM, Michael R. Wolf <span dir="ltr"><<a href="mailto:MichaelRWolf@att.net">MichaelRWolf@att.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Anyone used TT2 and Module::Build together?<br>
<br>
I'm looking for a (non-web) set of best (or at least OK) practices that works with Module::Build. I'm familiar with the basics of Build.PL for creating and installing a module (or 3), but could use some guidance for the "ancillary" pieces of a distribution that needs run-time non-module parts.<br>
<br>
By "best practice", I mean a combination of practices in client code, Build.PL, and directory structure that works well with<br>
- Build && Build test # regression testing<br>
- perl -I blib/lib t/xxx.t # debugging modules<br>
- perl -I blib/lib bin/<a href="http://main.pl" target="_blank">main.pl</a><br>
- Build dist # distribution<br>
- Build install # client installation<br>
<br>
* Where did you put the templates (*.tt) and the stand-alone Perl programs (*.pl) relative to Dist-Name/lib/Dist/Name.pm?<br>
* How did that change from development to deployment?<br>
* How did the 'main' program reference the the template directories in Template->new( { INCLUDE_PATH => [dir1 dir2] } )?<br>
* What sections did you use in Build.PL to make sure the *.pl and *.tt files worked with Build targes of 'test', 'dist', and 'install'?<br>
* Was $FindBin::Bin/../dir1/dir2 a part of the solution? Or was there some library-relative piece?<br>
<br>
It might be instructive to me (and others) to do a 'ls -r' in a new distribution, and various cut/paste references to *.tt and *.pl from Build.pl and <a href="http://main-program.pl" target="_blank">main-program.pl</a>.<br>
<br>
Alternatively, a URL to a better description of Buld.PL (no, not how to sub-class it, how to *use* it as it is -- just my beef with the "Cookbook" and "Authoring". OK end mini-rant)<br>
<br>
...Or a suggestion of a CPAN module that does it well.<br>
<br>
Thanks...<br>
<br>
--<br>
Michael R. Wolf<br>
All mammals learn by playing!<br>
<a href="mailto:MichaelRWolf@att.net">MichaelRWolf@att.net</a><br>
<br>
<br>
<br>
_____________________________________________________________<br>
Seattle Perl Users Group Mailing List<br>
POST TO: <a href="mailto:spug-list@pm.org">spug-list@pm.org</a><br>
SUBSCRIPTION: <a href="http://mail.pm.org/mailman/listinfo/spug-list" target="_blank">http://mail.pm.org/mailman/listinfo/spug-list</a><br>
MEETINGS: 3rd Tuesdays<br>
WEB PAGE: <a href="http://seattleperl.org/" target="_blank">http://seattleperl.org/</a><br>
</blockquote></div><br>