<commit_before>SUMMARY = "ITS Tool allows you to translate your XML documents with PO files"
HOMEPAGE = "http://itstool.org/"
LICENSE = "GPLv3"
LIC_FILES_CHKSUM = "file://COPYING;md5=59c57b95fd7d0e9e238ebbc7ad47c5a5"

inherit autotools python3native

DEPENDS = "libxml2-native"

SRC_URI = "http://files.itstool.org/${BPN}/${BPN}-${PV}.tar.bz2"
SRC_URI[md5sum] = "655c6f78fc64faee45adcc45ccc5a57e"
SRC_URI[sha256sum] = "100506f8df62cca6225ec3e631a8237e9c04650c77495af4919ac6a100d4b308"

do_install_append() {
    # fix shebang of main script
    sed -i 's:^#!${WORKDIR}.*${PYTHON_PN} -s:#!${bindir_native}/${PYTHON_PN} -s:' ${D}${bindir}/itstool
}

BBCLASSEXTEND = "native"

RDEPENDS_${PN} += "libxml2-python"
<commit_msg>itstool: use libxml2 to instead of python3-lxml<commit_after>SUMMARY = "ITS Tool allows you to translate your XML documents with PO files"
HOMEPAGE = "http://itstool.org/"
LICENSE = "GPLv3"
LIC_FILES_CHKSUM = "file://COPYING;md5=59c57b95fd7d0e9e238ebbc7ad47c5a5"

inherit autotools python3native

DEPENDS = "libxml2-native"

SRC_URI = "http://files.itstool.org/${BPN}/${BPN}-${PV}.tar.bz2"
SRC_URI[md5sum] = "655c6f78fc64faee45adcc45ccc5a57e"
SRC_URI[sha256sum] = "100506f8df62cca6225ec3e631a8237e9c04650c77495af4919ac6a100d4b308"

do_install_append() {
    # fix shebang of main script
    sed -i 's:^#!${WORKDIR}.*${PYTHON_PN} -s:#!${bindir_native}/${PYTHON_PN} -s:' ${D}${bindir}/itstool
}

BBCLASSEXTEND = "native"

RDEPENDS_${PN} += "libxml2-python"
RDEPENDS_${PN}_class-native = ""
{'fraction_non_alphanumeric': 0.15450928381962864, 'fraction_numerical': 0.11538461538461539, 'mean_word_length': 6.433497536945813, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 6}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2760128', 'n_tokens_mistral': 767, 'n_tokens_neox': 684, 'n_words': 99}