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