Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add a better failsafe for finding p5helper
  • Loading branch information
lizmat committed May 5, 2015
1 parent 438d023 commit f6e2993
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/Inline/Perl5.pm6
Expand Up @@ -34,7 +34,13 @@ sub native(Sub $sub) {
}
}
unless $path { # TEMPORARY !!!!
$path = $?FILE.substr(0,*-9) ~ $so;
for @*INC.grep(Str) {
my $file = "$_.substr(5)/Inline/$so";
if $file.IO.e {
$path = $file;
last;
}
}
}
unless $path {
die "unable to find Inline/$so IN \@*INC";
Expand Down

0 comments on commit f6e2993

Please sign in to comment.