开发者

How to copy files with Makefile.PL and ExtUtils::MakeMaker?

I am developing a library and开发者_Python百科 scripts in perl. For distribution I am using ExtUtils::MakeMaker, I have some configuration and data files in a directory called data in the distribution path, for example the config file is data/config.ini and data files like: data/inv01.stb. A part of the Makefile.PL code follows:

use ExtUtils::MakeMaker;

my $inifile = 'data/config.ini';
my @data    = <data/*.stb>;    

WriteMakefile(
  NAME => 'Mymodule',
  VERSION_FROM   => 'lib/Mymodule.pm',
  PREREQ_PM  => {
    'Time::HiRes' => 0,
    'Storable'    => 0,
    'File::Path', => 0,
    'File::Copy', => 0,
    'Digest::CRC', => 0,
    'Digest::MD5', => 0,
    'Archive::Tar', => 0,

  },
  EXE_FILES => [ qw(scripts/check_requests.pl  scripts/proc_requests.pl scripts/send_requests.pl) ],
  'clean' => {FILES => clean_files()},
);

# Delete *~ files 
sub clean_files {      
  return join(" ", "*.out", "*~", "data/test/*");
}

How can I configure the Makefile.PL to copy those files in non standard directory.

thanks for your help


Why not use EXE_FILES? After all, they are not going to be checked for runability.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜