Installing extra data files with a Makefile.PL?

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
Hi Usenet,

I have written a module with some additional files. These additional
files are some kind of text database for running the module. My question
is: how can I install these additional files with the 'Makefile.PL'? How
can I bring Makefile.PL to copy some text files to '/usr/share/foobar'?

I read the man pages of ExtUtils::MakeMaker,
ExtUtils::MakeMaker::Tutorial, perlmodstyle and perlnewmod but there was
nothing of interests for this problem (or I don't have seen them, links
are welcome).

How does others modules solve this problem of data files? I know the way
of using Data::Dumper to make a perl dump of data but I would prefer the
plain text files because so I can edit the data in a very easy way.

Does anyone know a modul with some extra-data?

So long... Fuzz

Re: Installing extra data files with a Makefile.PL?

Erik Wasser wrote:
Quoted text here. Click to load it

One way is to just set up a dialogue within Makefile.PL
(ExtUtils::MakeMaker has a prompt subroutine) to ask the
user where they want to install the data file, and then
just copy it over. Alternatively, you can add the relevant
command to the "install" target (see the section on overriding
MakeMaker methods in the ExtUtils::MakeMaker docs) to have
the file copied at the "make install" stage.

best regards,
randy kobes

Site Timeline