mirror of
git://git.yoctoproject.org/meta-virtualization.git
synced 2025-07-19 20:59:41 +02:00
lopper, python-dtc: add new recipes for device tree tools
This device tree tooling is being added as a prequisite for enabling qemuboot with the Arm 64-bit version of the Xen hypervisor. lopper: a tool for performing operations on device tree files. A new recipe inspired by the original from meta-xilinx-bsp. python-dtc: a python library for the Device Tree compiler. This is a prerequisite for lopper. Updated import of recipe from meta-xilinx-bsp for the latest release, version 1.6.1. Signed-off-by: Christopher Clark <christopher.clark@starlab.io> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
parent
11036424a9
commit
29796322c2
28
recipes-kernel/dtc/python3-dtc_1.6.1.bb
Normal file
28
recipes-kernel/dtc/python3-dtc_1.6.1.bb
Normal file
|
@ -0,0 +1,28 @@
|
|||
SUMMARY = "Python Library for the Device Tree Compiler"
|
||||
HOMEPAGE = "https://devicetree.org/"
|
||||
DESCRIPTION = "A python library for the Device Tree Compiler, a tool used to manipulate Device Tree files which contain a data structure for describing hardware."
|
||||
SECTION = "bootloader"
|
||||
LICENSE = "GPLv2 | BSD"
|
||||
|
||||
DEPENDS = "flex-native bison-native swig-native libyaml dtc"
|
||||
|
||||
SRC_URI = "git://git.kernel.org/pub/scm/utils/dtc/dtc.git"
|
||||
|
||||
UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://pylibfdt/libfdt.i;beginline=1;endline=6;md5=afda088c974174a29108c8d80b5dce90"
|
||||
|
||||
SRCREV = "ecaeb97fec013973360e94888a7de645f084345c"
|
||||
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
inherit distutils3
|
||||
|
||||
DISTUTILS_SETUP_PATH = "${S}/pylibfdt"
|
||||
|
||||
do_configure_prepend() {
|
||||
oe_runmake -C "${S}" version_gen.h
|
||||
mv "${S}/version_gen.h" "${DISTUTILS_SETUP_PATH}/"
|
||||
}
|
||||
|
||||
BBCLASSEXTEND = "native nativesdk"
|
45
recipes-kernel/lopper/lopper.bb
Normal file
45
recipes-kernel/lopper/lopper.bb
Normal file
|
@ -0,0 +1,45 @@
|
|||
SUMMARY = "Device Tree Lopper"
|
||||
DESCRIPTION = "Tool for manipulation of system device tree files"
|
||||
LICENSE = "BSD-3-Clause"
|
||||
SECTION = "bootloader"
|
||||
|
||||
SRC_URI = "git://github.com/devicetree-org/lopper.git"
|
||||
SRCREV = "0c23e51d585608ab04009ccf3499f168e2f4d478"
|
||||
S = "${WORKDIR}/git"
|
||||
|
||||
LIC_FILES_CHKSUM = "file://LICENSE.md;md5=8e5f5f691f01c9fdfa7a7f2d535be619"
|
||||
|
||||
RDEPENDS_${PN} = " \
|
||||
python3-core \
|
||||
python3-dtc \
|
||||
python3-humanfriendly \
|
||||
"
|
||||
|
||||
do_install() {
|
||||
install -d "${D}/${bindir}"
|
||||
install -d "${D}/${datadir}/${BPN}"
|
||||
|
||||
install -m 0644 "${S}/README" "${D}/${datadir}/${BPN}"
|
||||
install -m 0644 "${S}/README-architecture.txt" "${D}/${datadir}/${BPN}"
|
||||
install -m 0644 "${S}/README.pydoc" "${D}/${datadir}/${BPN}"
|
||||
install -m 0644 "${S}/LICENSE.md" "${D}/${datadir}/${BPN}"
|
||||
|
||||
install -d "${D}/${datadir}/${BPN}/assists"
|
||||
install -m 0644 "${S}/assists/"* "${D}/${datadir}/${BPN}/assists/"
|
||||
|
||||
install -d "${D}/${datadir}/${BPN}/lops"
|
||||
install -m 0644 "${S}/lops/"* "${D}/${datadir}/${BPN}/lops/"
|
||||
|
||||
install -d "${D}/${datadir}/${BPN}/device-trees"
|
||||
install -m 0644 "${S}/device-trees/"* "${D}/${datadir}/${BPN}/device-trees/"
|
||||
|
||||
install -m 0755 "${S}/"lopper*.py "${D}/${datadir}/${BPN}/"
|
||||
|
||||
datadir_relpath=${@os.path.relpath(d.getVar('datadir'), d.getVar('bindir'))}
|
||||
ln -s "${datadir_relpath}/${BPN}/lopper.py" "${D}/${bindir}/"
|
||||
}
|
||||
|
||||
do_configure[noexec] = "1"
|
||||
do_compile[noexec] = "1"
|
||||
|
||||
BBCLASSEXTEND = "native nativesdk"
|
Loading…
Reference in New Issue
Block a user