mirror of
https://git.yoctoproject.org/poky
synced 2026-02-20 08:29:42 +01:00
In the meta-rust repo at commit: 448047c Upgrade to 1.54.0 (#359) Make the required directories: mkdir ../oe-core/meta/recipes-devtools/rust mkdir ../oe-core/meta/recipes-devtools/cargo mkdir ../oe-core/meta/recipes-example and then: cp recipes-devtools/rust/* ../oe-core/meta/recipes-devtools/rust cp recipes-devtools/cargo/* ../oe-core/meta/recipes-devtools/cargo cp lib/crate.py ../oe-core/meta/lib cp recipes-example/* ../oe-core/meta/recipes-example cp conf/distro/include/rust_* ../oe-core/meta/conf/distro/include/ cp classes/* ../oe-core/meta/classes/ cp recipes-core/packagegroups/packagegroup-rust-cross-canadian.bb ../oe-core/meta/recipes-core/packagegroups (From OE-Core rev: 3ed57578cca93ff1ba4e0bf3f25566e10659a2f9) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
39 lines
1.3 KiB
PHP
39 lines
1.3 KiB
PHP
|
|
require rust-cross-canadian-common.inc
|
|
|
|
RUST_TOOLS_CLIPPY_PN = "rust-tools-clippy-cross-canadian-${TRANSLATED_TARGET_ARCH}"
|
|
RUST_TOOLS_RUSTFMT_PN = "rust-tools-rustfmt-cross-canadian-${TRANSLATED_TARGET_ARCH}"
|
|
RUST_TOOLS_PKGS = "${RUST_TOOLS_CLIPPY_PN} ${RUST_TOOLS_RUSTFMT_PN}"
|
|
PN = "rust-tools-cross-canadian-${TRANSLATED_TARGET_ARCH}"
|
|
|
|
PACKAGES = "${RUST_TOOLS_CLIPPY_PN} ${RUST_TOOLS_RUSTFMT_PN} ${PN}"
|
|
RDEPENDS:${PN} += "${RUST_TOOLS_PKGS}"
|
|
|
|
do_compile () {
|
|
rust_runx build --stage 2 src/tools/clippy
|
|
rust_runx build --stage 2 src/tools/rustfmt
|
|
}
|
|
|
|
do_install () {
|
|
SYS_BINDIR=$(dirname ${D}${bindir})
|
|
|
|
install -d "${SYS_BINDIR}"
|
|
cp build/${SNAPSHOT_BUILD_SYS}/stage2-tools-bin/* ${SYS_BINDIR}
|
|
for i in ${SYS_BINDIR}/*; do
|
|
chrpath -r "\$ORIGIN/../lib" ${i}
|
|
done
|
|
|
|
chown -R root.root ${D}
|
|
}
|
|
|
|
ALLOW_EMPTY:${PN} = "1"
|
|
|
|
PKG_SYS_BINDIR = "${SDKPATHNATIVE}/usr/bin"
|
|
FILES:${RUST_TOOLS_CLIPPY_PN} = "${PKG_SYS_BINDIR}/cargo-clippy ${PKG_SYS_BINDIR}/clippy-driver"
|
|
FILES:${RUST_TOOLS_RUSTFMT_PN} = "${PKG_SYS_BINDIR}/rustfmt"
|
|
|
|
SUMMARY:${PN} = "Rust helper tools"
|
|
SUMMARY:${RUST_TOOLS_CLIPPY_PN} = "A collection of lints to catch common mistakes and improve your Rust code"
|
|
SUMMARY:${RUST_TOOLS_RUSTFMT_PN} = "A tool for formatting Rust code according to style guidelines"
|
|
|