2007-05-27 21:04:11 +00:00
|
|
|
DESCRIPTION = "Perl is a popular scripting language."
|
|
|
|
HOMEPAGE = "http://www.perl.org/"
|
|
|
|
SECTION = "libs"
|
2012-03-13 23:46:14 +00:00
|
|
|
LICENSE = "Artistic-1.0 | GPL-1.0"
|
2013-01-21 09:03:21 +00:00
|
|
|
PR = "r0"
|
2007-05-27 21:04:11 +00:00
|
|
|
|
2010-12-23 00:40:57 +00:00
|
|
|
LIC_FILES_CHKSUM = "file://Copying;md5=2b4c6ffbcfcbdee469f02565f253d81a \
|
|
|
|
file://Artistic;md5=f921793d03cc6d63ec4b15e9be8fd3f8"
|
|
|
|
|
2012-09-09 09:13:08 +00:00
|
|
|
# 5.10.1 has Module::Build built-in
|
|
|
|
PROVIDES += "libmodule-build-perl-native"
|
|
|
|
|
2011-06-11 10:50:21 +00:00
|
|
|
SRC_URI = "http://www.cpan.org/src/5.0/perl-${PV}.tar.gz \
|
2011-03-18 05:40:15 +00:00
|
|
|
file://Configure-multilib.patch \
|
|
|
|
file://perl-configpm-switch.patch \
|
|
|
|
file://native-nopacklist.patch \
|
2011-08-16 06:53:59 +00:00
|
|
|
file://native-perlinc.patch \
|
2012-06-04 18:47:44 +00:00
|
|
|
file://MM_Unix.pm.patch \
|
2013-01-19 23:48:46 +00:00
|
|
|
file://debian/errno_ver.diff \
|
2013-01-19 23:49:24 +00:00
|
|
|
file://dynaloaderhack.patch \
|
2012-06-04 18:47:44 +00:00
|
|
|
file://perl-build-in-t-dir.patch"
|
2007-05-27 21:04:11 +00:00
|
|
|
|
2013-01-21 09:03:21 +00:00
|
|
|
SRC_URI[md5sum] = "f6a3d878c688d111b495c87db56c5be5"
|
|
|
|
SRC_URI[sha256sum] = "03638a4f01bc26b81231233671524b4163849a3a9ea5cc2397293080c4ea339f"
|
2010-12-08 04:06:29 +00:00
|
|
|
|
2007-05-27 21:04:11 +00:00
|
|
|
S = "${WORKDIR}/perl-${PV}"
|
|
|
|
|
|
|
|
inherit native
|
|
|
|
|
2011-05-31 07:07:56 +00:00
|
|
|
NATIVE_PACKAGE_PATH_SUFFIX = "/${PN}"
|
|
|
|
|
2011-03-18 05:40:15 +00:00
|
|
|
export LD="${CCLD}"
|
|
|
|
|
2007-05-27 21:04:11 +00:00
|
|
|
do_configure () {
|
2009-11-18 20:05:55 +00:00
|
|
|
./Configure \
|
|
|
|
-Dcc="${CC}" \
|
|
|
|
-Dcflags="${CFLAGS}" \
|
|
|
|
-Dldflags="${LDFLAGS}" \
|
|
|
|
-Dcf_by="Open Embedded" \
|
|
|
|
-Dprefix=${prefix} \
|
|
|
|
-Dvendorprefix=${prefix} \
|
|
|
|
-Dvendorprefix=${prefix} \
|
|
|
|
-Dsiteprefix=${prefix} \
|
|
|
|
\
|
2011-05-31 07:07:56 +00:00
|
|
|
-Dbin=${STAGING_BINDIR}/${PN} \
|
2011-02-01 23:18:29 +00:00
|
|
|
-Dprivlib=${STAGING_LIBDIR}/perl/${PV} \
|
|
|
|
-Darchlib=${STAGING_LIBDIR}/perl/${PV} \
|
|
|
|
-Dvendorlib=${STAGING_LIBDIR}/perl/${PV} \
|
|
|
|
-Dvendorarch=${STAGING_LIBDIR}/perl/${PV} \
|
|
|
|
-Dsitelib=${STAGING_LIBDIR}/perl/${PV} \
|
|
|
|
-Dsitearch=${STAGING_LIBDIR}/perl/${PV} \
|
2009-11-18 20:05:55 +00:00
|
|
|
\
|
2011-02-01 23:18:29 +00:00
|
|
|
-Duseshrplib \
|
2009-11-18 20:05:55 +00:00
|
|
|
-Dusethreads \
|
|
|
|
-Duseithreads \
|
|
|
|
-Duselargefiles \
|
|
|
|
-Dnoextensions=ODBM_File \
|
|
|
|
-Ud_dosuid \
|
|
|
|
-Ui_db \
|
|
|
|
-Ui_ndbm \
|
|
|
|
-Ui_gdbm \
|
|
|
|
-Di_shadow \
|
|
|
|
-Di_syslog \
|
|
|
|
-Duseperlio \
|
|
|
|
-Dman3ext=3pm \
|
2013-09-25 12:36:00 +00:00
|
|
|
-Dsed=/bin/sed \
|
2009-11-18 20:05:55 +00:00
|
|
|
-Uafs \
|
|
|
|
-Ud_csh \
|
|
|
|
-Uusesfio \
|
|
|
|
-Uusenm -des
|
2007-05-27 21:04:11 +00:00
|
|
|
}
|
2009-11-18 20:05:55 +00:00
|
|
|
|
|
|
|
do_install () {
|
|
|
|
oe_runmake 'DESTDIR=${D}' install
|
|
|
|
|
|
|
|
# We need a hostperl link for building perl
|
|
|
|
ln -sf perl${PV} ${D}${bindir}/hostperl
|
|
|
|
|
2010-12-22 17:26:07 +00:00
|
|
|
ln -sf perl ${D}${libdir}/perl5
|
|
|
|
|
2009-11-18 20:05:55 +00:00
|
|
|
install -d ${D}${libdir}/perl/${PV}/CORE \
|
|
|
|
${D}${datadir}/perl/${PV}/ExtUtils
|
|
|
|
|
|
|
|
# Save native config
|
|
|
|
install config.sh ${D}${libdir}/perl
|
|
|
|
install lib/Config.pm ${D}${libdir}/perl/${PV}/
|
2010-12-22 17:26:07 +00:00
|
|
|
install lib/ExtUtils/typemap ${D}${libdir}/perl/${PV}/ExtUtils/
|
2009-11-18 20:05:55 +00:00
|
|
|
|
|
|
|
# perl shared library headers
|
2011-10-19 21:53:17 +00:00
|
|
|
for i in av.h bitcount.h config.h cop.h cv.h dosish.h embed.h embedvar.h \
|
|
|
|
EXTERN.h fakesdio.h fakethr.h form.h gv.h handy.h hv.h INTERN.h \
|
|
|
|
intrpvar.h iperlsys.h keywords.h l1_char_class_tab.h malloc_ctl.h \
|
|
|
|
metaconfig.h mg.h mydtrace.h nostdio.h opcode.h op.h opnames.h \
|
|
|
|
op_reg_common.h overload.h pad.h parser.h patchlevel.h perlapi.h \
|
|
|
|
perl.h perlio.h perliol.h perlsdio.h perlsfio.h perlvars.h \
|
|
|
|
perly.h pp.h pp_proto.h proto.h reentr.h regcharclass.h regcomp.h \
|
|
|
|
regexp.h regnodes.h scope.h sv.h thread.h time64_config.h \
|
|
|
|
time64.h uconfig.h unixish.h utf8.h utfebcdic.h util.h \
|
|
|
|
uudmap.h warnings.h XSUB.h
|
|
|
|
do
|
2009-11-18 20:05:55 +00:00
|
|
|
install $i ${D}${libdir}/perl/${PV}/CORE
|
|
|
|
done
|
2011-01-12 17:29:40 +00:00
|
|
|
|
2011-04-24 02:43:17 +00:00
|
|
|
create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/'
|
2011-05-16 20:14:12 +00:00
|
|
|
create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/'
|
2009-11-18 20:05:55 +00:00
|
|
|
}
|
2011-07-19 15:49:42 +00:00
|
|
|
|
|
|
|
SYSROOT_PREPROCESS_FUNCS += "perl_sysroot_create_wrapper"
|
|
|
|
|
|
|
|
perl_sysroot_create_wrapper () {
|
|
|
|
mkdir -p ${SYSROOT_DESTDIR}${bindir}
|
|
|
|
# Create a wrapper that /usr/bin/env perl will use to get perl-native.
|
|
|
|
# This MUST live in the normal bindir.
|
|
|
|
cat > ${SYSROOT_DESTDIR}${bindir}/../nativeperl << EOF
|
|
|
|
#!/bin/sh
|
|
|
|
realpath=\`readlink -fn \$0\`
|
|
|
|
exec \`dirname \$realpath\`/perl-native/perl "\$@"
|
|
|
|
EOF
|
|
|
|
chmod 0755 ${SYSROOT_DESTDIR}${bindir}/../nativeperl
|
|
|
|
cat ${SYSROOT_DESTDIR}${bindir}/../nativeperl
|
|
|
|
}
|