summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/perl/files/perl-dynloader.patch
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2019-06-17 16:48:59 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-06-18 11:23:48 +0100
commit6896ca82f106c65e6c7d08986cfe86d2305c6afa (patch)
treea9af7a0bb0371d61c86376805798839e4ad6e052 /meta/recipes-devtools/perl/files/perl-dynloader.patch
parent646b596c99119f40060d84a4bc6349f3a2a4e893 (diff)
downloadpoky-6896ca82f106c65e6c7d08986cfe86d2305c6afa.tar.gz
perl: Move perl-sanity -> perl
This was moved during the perl cleanup, it can/should be moved back now as its confusing too many people. (From OE-Core rev: ce69c21707aa19ab8a3f6c07dc5a560671ab53a4) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/perl/files/perl-dynloader.patch')
-rw-r--r--meta/recipes-devtools/perl/files/perl-dynloader.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-devtools/perl/files/perl-dynloader.patch b/meta/recipes-devtools/perl/files/perl-dynloader.patch
new file mode 100644
index 0000000000..6bb832a426
--- /dev/null
+++ b/meta/recipes-devtools/perl/files/perl-dynloader.patch
@@ -0,0 +1,38 @@
1Upstream-Status:Inappropriate [embedded specific]
2
3Allow the location that .so files are searched for for dynamic
4loading to be changed via an environment variable. This is to allow
5us to load .so's from the host system while building for the target
6system.
7
8Update by Nitin A Kamble <nitin.a.kamble@intel.com> 2011/04/21
9
10Index: perl-5.24.1/dist/XSLoader/XSLoader_pm.PL
11===================================================================
12--- perl-5.24.1.orig/dist/XSLoader/XSLoader_pm.PL
13+++ perl-5.24.1/dist/XSLoader/XSLoader_pm.PL
14@@ -52,6 +52,24 @@ sub load {
15 my ($caller, $modlibname) = caller();
16 my $module = $caller;
17
18+ # OE: Allow env to form dynamic loader to look in a different place
19+ # This is so it finds the host .so files, not the targets
20+ if (defined $ENV{PERLHOSTLIB})
21+ {
22+ my $hostlib = $ENV{PERLHOSTLIB};
23+ my $hostarchlib = $ENV{PERLHOSTARCHLIB};
24+ print STDERR "*** Module name IN: $modlibname\n";
25+ ($p1, $p2, $p3, $p4, $p5, $p6, $p7) = $modlibname =~ m/(^(.*lib\w*\/)?)((perl5\/[0-9\.]*\/)?)(([^\/]*)\/)?(.*)$/;
26+ print STDERR "*** p1: $p1 p3: $p3 p5: $p5 p7: $p7\n";
27+ if ( $p1 ne "" ) {
28+ $modlibname = $hostlib.$p7;
29+ }
30+ if ( $p6 ne "" ) {
31+ $modlibname = $hostarchlib.$p7;
32+ }
33+ print STDERR "*** Module name OUT: $modlibname\n";
34+ }
35+
36 if (@_) {
37 $module = $_[0];
38 } else {