File: Build.PL

package info (click to toggle)
libsvn-notify-perl 2.86-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 536 kB
  • ctags: 68
  • sloc: perl: 3,617; makefile: 2
file content (66 lines) | stat: -rw-r--r-- 2,267 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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
use Module::Build;
use Config;
use strict;

my $class = Module::Build->subclass(
    class => 'My::Builder',
    code => q{
             sub ACTION_code {
                 my $self = shift;
                 $self->SUPER::ACTION_code(@_);
                 # Copy the test scripts and then set the shebang line and make
                 # sure that they're executable.
                 my @scripts;
                 my $to_dir = $self->localize_file_path("t/scripts");
                 for my $base (qw(testsvnlook testsendmail)) {
                     my $script = "$to_dir/$base";
                     push @scripts, $self->localize_file_path($script);
                     my $orig = $self->localize_file_path("t/bin/$base");
                     $self->copy_if_modified(
                         from    => $orig,
                         to_dir  => $to_dir,
                         flatten => 1,
                     );
                 }
                 $self->fix_shebang_line(@scripts);
                 $self->make_executable(@scripts);
                 $self->add_to_cleanup($to_dir);
             }
         },
);

my $build = $class->new(
    module_name        => 'SVN::Notify',
    license            => 'perl',
    add_to_cleanup     => [qw(t/data/output.txt t/scripts)],
    script_files       => ['bin/svnnotify'],
    configure_requires => { 'Module::Build' => '0.2701' },
    requires           => {
        'Email::Address' => '1.897',
        'Getopt::Long'   => '2.34',
        'perl'           => 5.006,
    },
    build_requires     => {
        'Test::More'    => '0.17',
        'Module::Build' => '0.2701',
        'File::Spec'    => 0,
    },
    recommends => {
        'Pod::Usage'          => '1.33',
        'HTML::Entities'      => 0,
        'Net::SMTP::TLS'      => 0,
        'Test::Pod'           => 1.41,
        'Test::Pod::Coverage' => 1.06,
        'File::Spec'          => 0,
        'Text::Trac'          => '0.10',
    },
    meta_merge => {
        resources => {
            homepage   => 'http://search.cpan.org/dist/SVN-Notify/',
            bugtracker => 'http://github.com/theory/svn-notify/issues/',
            repository => 'http://github.com/theory/svn-notify/',
        }
    },
);
$build->create_build_script;