line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
854
|
use strict; use warnings; |
|
1
|
|
|
1
|
|
1
|
|
|
1
|
|
|
|
|
45
|
|
|
1
|
|
|
|
|
5
|
|
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
53
|
|
2
|
|
|
|
|
|
|
package Module::Build::InlineModule; |
3
|
|
|
|
|
|
|
our $VERSION = '0.04'; |
4
|
|
|
|
|
|
|
|
5
|
1
|
|
|
1
|
|
17
|
use base 'Module::Build'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
593
|
|
6
|
|
|
|
|
|
|
__PACKAGE__->add_property('inline'); |
7
|
|
|
|
|
|
|
|
8
|
1
|
|
|
1
|
|
78016
|
use Inline::Module(); |
|
1
|
|
|
|
|
2820
|
|
|
1
|
|
|
|
|
201
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub ACTION_code { |
11
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
12
|
0
|
|
|
|
|
|
$self->SUPER::ACTION_code(@_); |
13
|
0
|
|
|
|
|
|
my $meta = $self->get_meta; |
14
|
0
|
|
|
|
|
|
my @inc = @INC; |
15
|
0
|
0
|
|
|
|
|
local @INC = ( |
16
|
|
|
|
|
|
|
(-e 'inc' ? ('inc') : ()), |
17
|
|
|
|
|
|
|
'lib', |
18
|
|
|
|
|
|
|
@inc, |
19
|
|
|
|
|
|
|
); |
20
|
0
|
|
|
|
|
|
for my $module (@{$meta->{module}}) { |
|
0
|
|
|
|
|
|
|
21
|
0
|
0
|
|
|
|
|
eval "require $module; 1" or die $@; |
22
|
|
|
|
|
|
|
} |
23
|
0
|
|
|
|
|
|
Inline::Module->handle_fixblib; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub ACTION_distdir { |
27
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
28
|
0
|
|
|
|
|
|
$self->SUPER::ACTION_distdir(@_); |
29
|
0
|
|
|
|
|
|
my $distdir = $self->dist_dir; |
30
|
0
|
|
|
|
|
|
my $meta = $self->get_meta; |
31
|
|
|
|
|
|
|
|
32
|
0
|
|
|
|
|
|
my $stub_modules = $meta->{stub}; |
33
|
0
|
|
|
|
|
|
my $included_modules = Inline::Module->included_modules($meta); |
34
|
|
|
|
|
|
|
|
35
|
0
|
|
|
|
|
|
my $files_added = Inline::Module->add_to_distdir( |
36
|
|
|
|
|
|
|
$distdir, |
37
|
|
|
|
|
|
|
$stub_modules, |
38
|
|
|
|
|
|
|
$included_modules, |
39
|
|
|
|
|
|
|
); |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
# XXX ask leont: |
42
|
|
|
|
|
|
|
# $self->_add_to_manifest($_) |
43
|
|
|
|
|
|
|
# for @$files_added; |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
sub get_meta { |
47
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
48
|
0
|
0
|
|
|
|
|
my $meta = $self->{properties}{inline} |
49
|
|
|
|
|
|
|
or die "Missing Module::Build property: 'inline'"; |
50
|
0
|
0
|
|
|
|
|
$meta->{module} or die |
51
|
|
|
|
|
|
|
"Module::Build::InlineModule property 'inline' missing key 'module'"; |
52
|
0
|
|
|
|
|
|
Inline::Module->default_meta($meta); |
53
|
0
|
|
|
|
|
|
return $meta; |
54
|
|
|
|
|
|
|
} |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
1; |