| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
# -*- mode: perl -*- |
|
2
|
1
|
|
|
1
|
|
223568
|
use alienfile 1.68; |
|
|
1
|
|
|
|
|
23
|
|
|
|
1
|
|
|
|
|
8
|
|
|
3
|
1
|
|
|
1
|
|
636
|
use Alien::Build::CommandSequence; |
|
|
1
|
|
|
|
|
4450
|
|
|
|
1
|
|
|
|
|
48
|
|
|
4
|
1
|
|
|
1
|
|
584
|
use lib q{lib}; |
|
|
1
|
|
|
|
|
783
|
|
|
|
1
|
|
|
|
|
6
|
|
|
5
|
1
|
|
|
1
|
|
632
|
use Alien::OpenMP::configure; |
|
|
1
|
|
|
|
|
3
|
|
|
|
1
|
|
|
|
|
438
|
|
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
configure { |
|
8
|
|
|
|
|
|
|
if ($^O eq 'darwin') { |
|
9
|
|
|
|
|
|
|
requires 'File::Which' => '1.27'; |
|
10
|
|
|
|
|
|
|
requires 'Path::Tiny' => '0.053'; |
|
11
|
|
|
|
|
|
|
} |
|
12
|
|
|
|
|
|
|
unless (Alien::OpenMP::configure->is_known) { |
|
13
|
|
|
|
|
|
|
Alien::OpenMP::configure->unsupported(__PACKAGE__); |
|
14
|
|
|
|
|
|
|
die "Unsupported platform (no OpenMP)"; |
|
15
|
|
|
|
|
|
|
} |
|
16
|
|
|
|
|
|
|
}; |
|
17
|
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
meta->interpolator->replace_helper(cc => sub { $Alien::OpenMP::configure::CCNAME }); |
|
19
|
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
plugin 'Probe::CBuilder' => ( |
|
21
|
|
|
|
|
|
|
lang => 'C', |
|
22
|
|
|
|
|
|
|
cflags => Alien::OpenMP::configure->cflags, |
|
23
|
|
|
|
|
|
|
libs => Alien::OpenMP::configure->libs, |
|
24
|
|
|
|
|
|
|
options => { quiet => 0 }, |
|
25
|
|
|
|
|
|
|
program => join("\n" => ), |
|
26
|
|
|
|
|
|
|
); |
|
27
|
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
after probe => sub { |
|
29
|
|
|
|
|
|
|
my $build = shift; |
|
30
|
|
|
|
|
|
|
$build->install_prop->{'alien_openmp_compiler_has_openmp'} = 1; |
|
31
|
|
|
|
|
|
|
$build->runtime_prop->{auto_include} = Alien::OpenMP::configure->auto_include; |
|
32
|
|
|
|
|
|
|
$build->runtime_prop->{version} = $Alien::OpenMP::VERSION; |
|
33
|
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
my $seq = Alien::Build::CommandSequence->new([ |
|
35
|
|
|
|
|
|
|
join(' ', '%{cc}', '-dM', Alien::OpenMP::configure->cflags, '-E', '-', '<', '%{devnull}'), |
|
36
|
|
|
|
|
|
|
sub { |
|
37
|
|
|
|
|
|
|
my ($build, $args) = @_; |
|
38
|
|
|
|
|
|
|
my @props = qw{openmp_version version}; |
|
39
|
|
|
|
|
|
|
my $runtime = Alien::OpenMP::configure->version_from_preprocessor($args->{out}); |
|
40
|
|
|
|
|
|
|
@{$build->runtime_prop}{@props} = @$runtime{@props}; |
|
41
|
|
|
|
|
|
|
} |
|
42
|
|
|
|
|
|
|
]); |
|
43
|
|
|
|
|
|
|
$seq->execute($build); |
|
44
|
|
|
|
|
|
|
}; |
|
45
|
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
share { |
|
47
|
|
|
|
|
|
|
before download => sub { |
|
48
|
|
|
|
|
|
|
my $build = shift; |
|
49
|
|
|
|
|
|
|
Alien::OpenMP::configure->unsupported($build); |
|
50
|
|
|
|
|
|
|
die "Unsupported platform, OpenMP will not be built"; |
|
51
|
|
|
|
|
|
|
}; |
|
52
|
|
|
|
|
|
|
}; |
|
53
|
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
__DATA__ |