Thanks for the concrete example!

I'm thinking though it might be easier to link the codebase lib directory into the build directory rather than the other way around, e.g.

#error checking, use... omitted #may have typos - read as perl-ish pseudocode my @buildirs = ("foo1", "foo2"); my $repo="myrepo"; my $startdir=File::Spec::curdir(); foreach my $buildme (@buildirs) { chdir($buildme); symlink($repo, "lib"); system("perl Build.PL"); unlink("lib"); } chdir($startdir);
The advantage of this approach is that I don't have to have to make assumptions about the support files used by the build process, e.g. is there a MANIFEST.SKIP? is there a special subclass of Module::Build that needs other kinds of support files?, etc, etc.

The main disadvantage of any linking approach is that it isn't well behaved on MS-Win platforms. Although I do most of my development on Linux, there are situations when I need to work on MS machines. Cygwin/Vista has a particularly nasty bug where un-linking a symbolic link defined in Vista via anything using cygwin libraries not only removes the link, but also the underlying file or directory!

beth

In reply to Re^2: How do I configure Module::Build to build multiple packages from the same lib directory? by ELISHEVA
in thread How do I configure Module::Build to build multiple packages from the same lib directory? 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.