On 03/09/01 18:30 +0100, Piers Harding wrote:
> Hi,
> 
> I'm trying to publish an Inline based suite that contains several
> modules in the same directory that have a C++ component, but I can't
> seem to figure out how to get them into the single Makefile.PL ( and
> hence Makefile ) to be built. Could someone please tell me how to do
> this? I have looked through the Inline mail archives and noticed
> someone else asking this question, but I don't seem to be able to find
> the answer. Also, it doesn't appear to be mentioned in Inline.pod
> which does talk about Inline::MakeMaker.

Piers,

At this point, Inline::MakeMaker assumes that you will have one
Makefile.PL and one (Inline-based) module per directory. So the best way
to set things up is to have a hierarchy of directories, with one module
per. You can build everything from the top level directory.
Makefile.PL-s work recursively and Inline::MakeMaker plays along fine.

Perl, for better or worse, allows you to create module distributions in
many different combinations of ways. You can put many modules in the
same directory, you can put hierarchies under a lib/ directory, you can
create subdirectories with their own Makefile.PL-s, you can mix these
all together. One other way that many people are not aware of is to just
define the last node of the module name, and then specify the entire
name in the NAME parameter of WriteMakefile. For instance is you wanted
to create the module Your::Brain::For::Once::Dude, you could just create
a file called Dude.pm at the top level and specify the full name in the
Makefile.PL. No need to create all the intervening directories under a
lib/ directory.

My point is that Inline doesn't support several modules in the same
directory, and it doesn't support the lib/ thing yet. But you
shouldn't need them. One big advantage to putting each module in a
separate subdirectory is that you can have README, Changes, etc files
for that module.

Hope that helps. Let me know if you get stuck. If so, be sure to forward
all details.

Cheers, Brian  

Reply via email to