summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/perl/perl-native_5.22.1.bb
diff options
context:
space:
mode:
authorAlejandro Hernandez <alejandro.hernandez@linux.intel.com>2016-01-20 15:56:57 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-01-24 09:40:20 +0000
commit55a8df2056024acf714f47c85267c1eba8b7b6be (patch)
treecfe6f9df7b309d7a296eabaf3dc30e2fab768793 /meta/recipes-devtools/perl/perl-native_5.22.1.bb
parenta84058826d913c093f088e929cb1f34ff413fa0c (diff)
downloadpoky-55a8df2056024acf714f47c85267c1eba8b7b6be.tar.gz
perl: Upgrade to 5.22.1
Rebased: - Makefile.SH.patch (From OE-Core rev: f4c9908eae1ae3dcc38877abe2d5fbeb46851dd4) Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/perl/perl-native_5.22.1.bb')
-rw-r--r--meta/recipes-devtools/perl/perl-native_5.22.1.bb125
1 files changed, 125 insertions, 0 deletions
diff --git a/meta/recipes-devtools/perl/perl-native_5.22.1.bb b/meta/recipes-devtools/perl/perl-native_5.22.1.bb
new file mode 100644
index 0000000000..9ffb24825b
--- /dev/null
+++ b/meta/recipes-devtools/perl/perl-native_5.22.1.bb
@@ -0,0 +1,125 @@
1require perl.inc
2
3SRC_URI += "\
4 file://Configure-multilib.patch \
5 file://perl-configpm-switch.patch \
6 file://native-nopacklist.patch \
7 file://native-perlinc.patch \
8 file://MM_Unix.pm.patch \
9 file://debian/errno_ver.diff \
10 file://dynaloaderhack.patch \
11 file://perl-PathTools-don-t-filter-out-blib-from-INC.patch \
12 "
13
14SRC_URI[md5sum] = "6671e4829cbaf9cecafa9a84f141b0a3"
15SRC_URI[sha256sum] = "9e87317d693ce828095204be0d09af8d60b8785533fadea1a82b6f0e071e5c79"
16
17inherit native
18
19NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
20
21export LD="${CCLD}"
22
23do_configure () {
24 ./Configure \
25 -Dcc="${CC}" \
26 -Dcflags="${CFLAGS}" \
27 -Dldflags="${LDFLAGS}" \
28 -Dcf_by="Open Embedded" \
29 -Dprefix=${prefix} \
30 -Dvendorprefix=${prefix} \
31 -Dsiteprefix=${prefix} \
32 \
33 -Dbin=${STAGING_BINDIR}/${PN} \
34 -Dprivlib=${STAGING_LIBDIR}/perl/${PV} \
35 -Darchlib=${STAGING_LIBDIR}/perl/${PV} \
36 -Dvendorlib=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
37 -Dvendorarch=${STAGING_LIBDIR}/perl/vendor_perl/${PV} \
38 -Dsitelib=${STAGING_LIBDIR}/perl/site_perl/${PV} \
39 -Dsitearch=${STAGING_LIBDIR}/perl/site_perl/${PV} \
40 \
41 -Duseshrplib \
42 -Dusethreads \
43 -Duseithreads \
44 -Duselargefiles \
45 -Dnoextensions=ODBM_File \
46 -Ud_dosuid \
47 -Ui_db \
48 -Ui_ndbm \
49 -Ui_gdbm \
50 -Ui_gdbm_ndbm \
51 -Ui_gdbmndbm \
52 -Di_shadow \
53 -Di_syslog \
54 -Duseperlio \
55 -Dman3ext=3pm \
56 -Dsed=/bin/sed \
57 -Uafs \
58 -Ud_csh \
59 -Uusesfio \
60 -Uusenm -des
61}
62
63do_install () {
64 oe_runmake 'DESTDIR=${D}' install
65
66 # We need a hostperl link for building perl
67 ln -sf perl${PV} ${D}${bindir}/hostperl
68
69 ln -sf perl ${D}${libdir}/perl5
70
71 install -d ${D}${libdir}/perl/${PV}/CORE \
72 ${D}${datadir}/perl/${PV}/ExtUtils
73
74 # Save native config
75 install config.sh ${D}${libdir}/perl
76 install lib/Config.pm ${D}${libdir}/perl/${PV}/
77 install lib/ExtUtils/typemap ${D}${libdir}/perl/${PV}/ExtUtils/
78
79 # perl shared library headers
80 # reference perl 5.20.0-1 in debian:
81 # https://packages.debian.org/experimental/i386/perl/filelist
82 for i in av.h bitcount.h charclass_invlists.h config.h cop.h cv.h dosish.h \
83 embed.h embedvar.h EXTERN.h fakesdio.h feature.h form.h git_version.h \
84 gv.h handy.h hv_func.h hv.h inline.h INTERN.h intrpvar.h iperlsys.h \
85 keywords.h l1_char_class_tab.h malloc_ctl.h metaconfig.h mg_data.h \
86 mg.h mg_raw.h mg_vtable.h mydtrace.h nostdio.h opcode.h op.h \
87 opnames.h op_reg_common.h overload.h pad.h parser.h patchlevel.h \
88 perlapi.h perl.h perlio.h perliol.h perlsdio.h perlvars.h perly.h \
89 pp.h pp_proto.h proto.h reentr.h regcharclass.h regcomp.h regexp.h \
90 regnodes.h scope.h sv.h thread.h time64_config.h time64.h uconfig.h \
91 unicode_constants.h unixish.h utf8.h utfebcdic.h util.h uudmap.h \
92 vutil.h warnings.h XSUB.h
93 do
94 install $i ${D}${libdir}/perl/${PV}/CORE
95 done
96
97 # Those wrappers mean that perl installed from sstate (which may change
98 # path location) works and that in the nativesdk case, the SDK can be
99 # installed to a different location from the one it was built for.
100 create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
101 create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/site_perl/${PV}:${STAGING_LIBDIR}/perl/vendor_perl/${PV}:${STAGING_LIBDIR}/perl/${PV}'
102
103 # Use /usr/bin/env nativeperl for the perl script.
104 for f in `grep -Il '#! *${bindir}/perl' ${D}/${bindir}/*`; do
105 sed -i -e 's|${bindir}/perl|/usr/bin/env nativeperl|' $f
106 done
107}
108
109SYSROOT_PREPROCESS_FUNCS += "perl_sysroot_create_wrapper"
110
111perl_sysroot_create_wrapper () {
112 mkdir -p ${SYSROOT_DESTDIR}${bindir}
113 # Create a wrapper that /usr/bin/env perl will use to get perl-native.
114 # This MUST live in the normal bindir.
115 cat > ${SYSROOT_DESTDIR}${bindir}/../nativeperl << EOF
116#!/bin/sh
117realpath=\`readlink -fn \$0\`
118exec \`dirname \$realpath\`/perl-native/perl "\$@"
119EOF
120 chmod 0755 ${SYSROOT_DESTDIR}${bindir}/../nativeperl
121 cat ${SYSROOT_DESTDIR}${bindir}/../nativeperl
122}
123
124# Fix the path in sstate
125SSTATE_SCAN_FILES += "*.pm *.pod *.h *.pl *.sh"