| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package ExtUtils::Builder::Binary; |
|
2
|
|
|
|
|
|
|
$ExtUtils::Builder::Binary::VERSION = '0.035'; |
|
3
|
4
|
|
|
4
|
|
2086
|
use strict; |
|
|
4
|
|
|
|
|
8
|
|
|
|
4
|
|
|
|
|
161
|
|
|
4
|
4
|
|
|
4
|
|
21
|
use warnings; |
|
|
4
|
|
|
|
|
12
|
|
|
|
4
|
|
|
|
|
264
|
|
|
5
|
|
|
|
|
|
|
|
|
6
|
4
|
|
|
4
|
|
25
|
use Carp qw//; |
|
|
4
|
|
|
|
|
26
|
|
|
|
4
|
|
|
|
|
125
|
|
|
7
|
4
|
|
|
4
|
|
657
|
use ExtUtils::Builder::Util qw/function/; |
|
|
4
|
|
|
|
|
13031
|
|
|
|
4
|
|
|
|
|
1362
|
|
|
8
|
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
my %allowed_types = map { ($_ => 1) } qw/shared-library static-library loadable-object executable/; |
|
10
|
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub _init { |
|
12
|
15
|
|
|
15
|
|
49
|
my ($self, %args) = @_; |
|
13
|
15
|
50
|
|
|
|
51
|
my $type = $args{type} or Carp::croak('No type given'); |
|
14
|
15
|
50
|
|
|
|
49
|
$allowed_types{$type} or Carp::croak("$type is not an allowed linkage type"); |
|
15
|
15
|
|
|
|
|
46
|
$self->{type} = $type; |
|
16
|
15
|
|
|
|
|
43
|
return; |
|
17
|
|
|
|
|
|
|
} |
|
18
|
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub type { |
|
20
|
29
|
|
|
29
|
0
|
55
|
my $self = shift; |
|
21
|
29
|
|
|
|
|
134
|
return $self->{type}; |
|
22
|
|
|
|
|
|
|
} |
|
23
|
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
sub _mkdir_for { |
|
25
|
0
|
|
|
0
|
|
|
my ($self, $file) = @_; |
|
26
|
0
|
|
|
|
|
|
my $dirname = File::Basename::dirname($file); |
|
27
|
0
|
|
|
|
|
|
return function( |
|
28
|
|
|
|
|
|
|
module => 'File::Path', |
|
29
|
|
|
|
|
|
|
function => 'make_path', |
|
30
|
|
|
|
|
|
|
exports => 'explicit', |
|
31
|
|
|
|
|
|
|
arguments => [ $dirname ], |
|
32
|
|
|
|
|
|
|
message => "mkdir $dirname", |
|
33
|
|
|
|
|
|
|
); |
|
34
|
|
|
|
|
|
|
} |
|
35
|
|
|
|
|
|
|
1; |
|
36
|
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
# ABSTRACT: Helper role for classes producing binary objects |
|
38
|
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
__END__ |