diff options
Diffstat (limited to 'meta/recipes-devtools/perl/libxml-parser-perl_2.46.bb')
-rw-r--r-- | meta/recipes-devtools/perl/libxml-parser-perl_2.46.bb | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/meta/recipes-devtools/perl/libxml-parser-perl_2.46.bb b/meta/recipes-devtools/perl/libxml-parser-perl_2.46.bb new file mode 100644 index 0000000000..bc154bbdc5 --- /dev/null +++ b/meta/recipes-devtools/perl/libxml-parser-perl_2.46.bb | |||
@@ -0,0 +1,58 @@ | |||
1 | SUMMARY = "XML::Parser - A perl module for parsing XML documents" | ||
2 | HOMEPAGE = "https://libexpat.github.io/" | ||
3 | SECTION = "libs" | ||
4 | LICENSE = "Artistic-1.0 | GPL-1.0+" | ||
5 | LIC_FILES_CHKSUM = "file://Parser.pm;beginline=1;endline=7;md5=d12cc778c80fc4c518f0e5dee29fd5fb" | ||
6 | |||
7 | DEPENDS += "expat" | ||
8 | |||
9 | SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Parser-${PV}.tar.gz \ | ||
10 | file://ptest-perl/run-ptest \ | ||
11 | file://0001-CheckLib.pm-do-not-attempt-to-run-a-cross-executable.patch \ | ||
12 | " | ||
13 | SRC_URI[md5sum] = "80bb18a8e6240fcf7ec2f7b57601c170" | ||
14 | SRC_URI[sha256sum] = "d331332491c51cccfb4cb94ffc44f9cd73378e618498d4a37df9e043661c515d" | ||
15 | |||
16 | S = "${WORKDIR}/XML-Parser-${PV}" | ||
17 | |||
18 | EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR} CC='${CC}' LD='${CCLD}' FULL_AR='${AR}'" | ||
19 | |||
20 | inherit cpan ptest-perl | ||
21 | |||
22 | # fix up sub MakeMaker project as arguments don't get propagated though | ||
23 | # see https://rt.cpan.org/Public/Bug/Display.html?id=28632 | ||
24 | do_configure_append_class-target() { | ||
25 | sed -E \ | ||
26 | -e 's:-L${STAGING_LIBDIR}::g' -e 's:-I${STAGING_INCDIR}::g' \ | ||
27 | -i Makefile Expat/Makefile | ||
28 | } | ||
29 | |||
30 | do_configure_append() { | ||
31 | sed -e 's:--sysroot=.*\(\s\|$\):--sysroot=${STAGING_DIR_TARGET} :g' \ | ||
32 | -i Makefile Expat/Makefile | ||
33 | sed 's:^FULL_AR = .*:FULL_AR = ${AR}:g' -i Expat/Makefile | ||
34 | # make sure these two do not build in parallel | ||
35 | sed 's!^$(INST_DYNAMIC):!$(INST_DYNAMIC): $(BOOTSTRAP)!' -i Expat/Makefile | ||
36 | } | ||
37 | |||
38 | do_compile() { | ||
39 | export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')" | ||
40 | cpan_do_compile | ||
41 | } | ||
42 | |||
43 | do_compile_class-native() { | ||
44 | cpan_do_compile | ||
45 | } | ||
46 | |||
47 | do_install_ptest() { | ||
48 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlstats | ||
49 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlfilter | ||
50 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlcomments | ||
51 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/canonical | ||
52 | cp -r ${B}/samples ${D}${PTEST_PATH} | ||
53 | chown -R root:root ${D}${PTEST_PATH}/samples | ||
54 | } | ||
55 | |||
56 | RDEPENDS_${PN}-ptest += "perl-module-filehandle perl-module-if perl-module-test perl-module-test-more" | ||
57 | |||
58 | BBCLASSEXTEND="native nativesdk" | ||