File: Build.PL

package info (click to toggle)
libextutils-cbuilder-perl 0.23-1
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 168 kB
  • ctags: 84
  • sloc: perl: 1,079; makefile: 8
file content (34 lines) | stat: -rw-r--r-- 876 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
use Module::Build;

my $class = Module::Build->subclass(code => <<'EOF');
  sub do_create_makefile_pl {
    my $self = shift;
    $self->SUPER::do_create_makefile_pl(fh => $fh);
    $self->do_system(qw(perl -pi -e), q{s/'INSTALLDIRS' => 'site'/'INSTALLDIRS' => (\$] >= 5.009003 ? 'perl' : 'site')/}, 'Makefile.PL');
  }
EOF

my $build = $class->new
  (
   module_name => 'ExtUtils::CBuilder',
   license => 'perl',
   requires => {
		'File::Basename' => 0,
		'File::Spec' => 0,
		'Text::ParseWords' => 0,
		'Cwd' => 0,
		'IO::File' => 0,
	       },
   build_requires => {
		      'Test' => 0,
		     },
   create_makefile_pl => 'traditional',
   create_readme => 1,
   meta_merge => {
		  resources => {repository => 'http://svn.perl.org/modules/ExtUtils-CBuilder'},
		 },
   sign => 1,
   installdirs => ($] >= 5.009003 ? 'core' : 'site'),
  );

$build->create_build_script;