Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | SUMMARY = "XML::Parser - A perl module for parsing XML documents" |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 2 | HOMEPAGE = "https://libexpat.github.io/" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 3 | SECTION = "libs" |
| 4 | LICENSE = "Artistic-1.0 | GPL-1.0+" |
| 5 | LIC_FILES_CHKSUM = "file://README;beginline=2;endline=6;md5=c8767d7516229f07b26e42d1cf8b51f1" |
| 6 | |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 7 | DEPENDS += "expat" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 8 | |
| 9 | SRC_URI = "http://www.cpan.org/modules/by-module/XML/XML-Parser-${PV}.tar.gz" |
| 10 | SRC_URI[md5sum] = "af4813fe3952362451201ced6fbce379" |
| 11 | SRC_URI[sha256sum] = "1ae9d07ee9c35326b3d9aad56eae71a6730a73a116b9fe9e8a4758b7cc033216" |
| 12 | |
| 13 | S = "${WORKDIR}/XML-Parser-${PV}" |
| 14 | |
| 15 | EXTRA_CPANFLAGS = "EXPATLIBPATH=${STAGING_LIBDIR} EXPATINCPATH=${STAGING_INCDIR} CC='${CC}' LD='${CCLD}' FULL_AR='${AR}'" |
| 16 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 17 | inherit cpan ptest-perl |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 18 | |
| 19 | # fix up sub MakeMaker project as arguments don't get propagated though |
| 20 | # see https://rt.cpan.org/Public/Bug/Display.html?id=28632 |
| 21 | do_configure_append() { |
| 22 | sed 's:--sysroot=.*\(\s\|$\):--sysroot=${STAGING_DIR_TARGET} :g' -i Makefile Expat/Makefile |
| 23 | sed 's:^FULL_AR = .*:FULL_AR = ${AR}:g' -i Expat/Makefile |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 24 | # make sure these two do not build in parallel |
| 25 | sed 's!^$(INST_DYNAMIC):!$(INST_DYNAMIC): $(BOOTSTRAP)!' -i Expat/Makefile |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 26 | } |
| 27 | |
| 28 | do_compile() { |
| 29 | export LIBC="$(find ${STAGING_DIR_TARGET}/${base_libdir}/ -name 'libc-*.so')" |
| 30 | cpan_do_compile |
| 31 | } |
| 32 | |
| 33 | do_compile_class-native() { |
| 34 | cpan_do_compile |
| 35 | } |
| 36 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 37 | do_install_ptest() { |
| 38 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlstats |
| 39 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlfilter |
| 40 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/xmlcomments |
| 41 | sed -i -e "s:/usr/local/bin/perl:/usr/bin/perl:g" ${B}/samples/canonical |
| 42 | cp -r ${B}/samples ${D}${PTEST_PATH} |
| 43 | chown -R root:root ${D}${PTEST_PATH}/samples |
| 44 | } |
| 45 | |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 46 | BBCLASSEXTEND="native nativesdk" |