summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rust
Commit message (Collapse)AuthorAgeFilesLines
* rust: add support for big endian 64-bit PowerPCDavid Joyner2021-10-271-0/+8
| | | | | | | | (From OE-Core rev: 91cc84afbfa6aad154f9a6402b538ea1b7c0ecd4) Signed-off-by: David Joyner <dbjoyner@amazon.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: Upgrade to 1.56.0Khem Raj2021-10-2314-192/+78
| | | | | | | | | | | | | | | This is latest major release, changes are here [1] Forward port libstd-rs patches and refresh musl/rv64 port [1] https://github.com/rust-lang/rust/releases/tag/1.56.0 (From OE-Core rev: 183204cbc70a4ef418b16df48bc7eb6e3a75a114) Signed-off-by: Khem Raj <raj.khem@gmail.com> Cc: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-cross: Fix directory not deleted for race glibc vs. muslPgowda2021-10-231-1/+1
| | | | | | | | | | | | Use different recipe names for the two different targets so that when switching libcs overlapping files in the sysroot don't cause issues. (From OE-Core rev: 33be44a02beb7c52f075f660ad8e0641e360011c) Signed-off-by: Pgowda <pgowda.cve@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Fix rust-native build issue when debug is enabledPgowda2021-10-141-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | When DEBUG_BUILD is set for building rust-native, it generated error as follows:- ========================================================= Building : rustdoc, rustdoc-json-types error[E0463]: can't find crate for `rustc_llvm` which `rustc_driver` depends on --> src/librustdoc/lib.rs:37:1 | 37 | extern crate rustc_driver; | ^^^^^^^^^^^^^^^^^^^^^^^^^^ can't find crate ========================================================= On analyzing the issue, it was found that rustc_llvm crate was present at required path. However, it was very huge due to the presence of debugging information. Hence, it was somehow not recognized as a valid crate. The following patch removes the debug information from rust-llvm-native which is built prior to rust-native but retains debug information as required in rust-native binaries. (From OE-Core rev: 7261a4b4d5778a48c8d72c9125233b1b0bc009e6) Signed-off-by: Pgowda <pgowda.cve@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: generate target definitions from (arch, abi), not just archAlexander Kanavin2021-10-142-23/+38
| | | | | | | | | | This allows to add the missing x32 definition and others in the future. (From OE-Core rev: 79bd6389585327820dfc1a1d29f60779ef08b2e0) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: do not write ar into target json definitionsAlexander Kanavin2021-10-141-1/+0
| | | | | | | | | | | latest rust does not use it and prints a ton of warnings because of it. (From OE-Core rev: 320f2c5aa535237fab4f4a1e6f75358f53221459) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust/cargo: exclude UNINATIVE_LOADER from task signatureAlexander Kanavin2021-10-141-0/+1
| | | | | | | | (From OE-Core rev: 8915dfa2034d939b504f134e83811ed2ba18a6f1) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: update 1.54.0 -> 1.55.0Alexander Kanavin2021-10-148-9/+9
| | | | | | | | (From OE-Core rev: a21705c33a6a69e9a625b8a75d76b76bd078aba2) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: drop PV from include file namesAlexander Kanavin2021-10-1414-30/+26
| | | | | | | | | | | This complicates (semi) automated upgrades, and isn't necessary as we carry only a single version of the toolchain. (From OE-Core rev: f7a6b23d99fba5855cfb34788199877a14206293) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: remove unused patchesMartin Jansa2021-09-022-101/+0
| | | | | | | | | | * 0001-nfc-Fix-missing-include.patch was only used in 1.51.0 version recently removed * 0001-rustc_target-Fix-dash-vs-underscore-mismatches-in-op.patch was only used in 1.49.0 version in meta-rust (From OE-Core rev: 52b12dac55a3747d8d6f2e799c669ef2bcda57ae) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: fix upstream version checksAlexander Kanavin2021-09-011-0/+3
| | | | | | | (From OE-Core rev: e2e87d82ad1ec071077f29613e2e568196912daa) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: Avoid buildtools+uninative issues with glibc symbols mismatchesRichard Purdie2021-08-261-0/+8
| | | | | | | | | | | | | | | If we use an external buildtools tarball, that combined with uninative results in build failures with symbol mismatches. This was tracked down to the prebuilt rust binaries that are downloaded. The libc/loader used to load them is used to execute target binaries/libraries and therefore anything with built with a newer libc would fail. Add code to use patchelf to change the interpreter to our own uninative one if present which ensures the newer libc and loader are used, hence avoiding the issue. (From OE-Core rev: 099c761ffddcc828329d3083cc8f3d24b43e9277) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: Skip target recipe since it doesn't workRichard Purdie2021-08-261-0/+7
| | | | | | | | | | | The target rust recipe is known not to work. Add a SkipRecipe entry for that so world builds don't include something known to be broken and hence give users a sensible message if they do try and build it rather than a build failure. (From OE-Core rev: 16c77c82ff6635b0180690ea117e2eff8fd63afb) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-llvm: Add missing HOMEPAGERichard Purdie2021-08-261-0/+1
| | | | | | | | Add a missing HOMEPAGE entry to the recipe (fixing a selftest failure). (From OE-Core rev: 71782d90cff825bd9c20d49590245565a6194bf8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-native: Avoid stripped warningRichard Purdie2021-08-261-0/+2
| | | | | | | | | | Instead of giving the following warning, hide it since we don't plan to change it. WARNING: rust-native-1.54.0-r0 do_populate_sysroot: File '/media/build1/poky/build/tmp/work/x86_64-linux/rust-native/1.54.0-r0/recipe-sysroot-native/usr/lib/rustlib/x86_64-linux/bin/rust-llvm-dwp' from rust-native was already stripped, this will prevent future debugging! (From OE-Core rev: ec5f0c77882ccbd5797519f5ded4e528eb687008) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-cross-canadian-common: Use rust.inc directly, not rust-targetRichard Purdie2021-08-261-1/+3
| | | | | | | | | We don't want cross-canadian to see the native BBCLASSEXTEND as that generates a recipe which makes no sense. Avoid this. (From OE-Core rev: f3648d18c4e05f38053bb1fd73796a6e05d61928) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-cross*: Fix OVERRRIDE references in task signature computationRichard Purdie2021-08-261-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The oeqa selftest test: sstatetests.SStateTests.test_sstate_sametune_samesigs which checks if the sstate checksums of two identical machines (using the same tune) are the same, apart from changes within the machine specific stamps directory, fails on the assertion: self.assertCountEqual(files1, files2) due to the signature of various 32 bit package builds such as: x86_64-linux/lib32-rust-cross-i686 x86_64-linux/rust-cross-i686 x86-pokymllib32-linux/lib32-libstd-rs x86-pokymllib32-linux/lib32-rust differing. Jumping down the rabbit hole past all the bitbake-diffsig outputs that differ due to dependent hashes, you come to a diff of: -Variable MACHINEOVERRIDES value is ${@bb.utils.contains('TUNE_FEATURES', 'mx32', 'x86-x32:', '', d)}${@bb.utils.contains('TUNE_FEATURES', 'm32', 'x86:', '', d)}qemuall:${MACHINE} +Variable MACHINEOVERRIDES value is ${@bb.utils.contains('TUNE_FEATURES', 'mx32', 'x86-x32:', '', d)}${@bb.utils.contains('TUNE_FEATURES', 'm32', 'x86:', '', d)}qemuall:${MACHINE}:qemux86 in stamps/x86_64-linux/rust-cross-i686/1.54.0-r0.do_rust_gen_target.<sig> This is because there are two rust functions referencing OVERRIDES related variables (target_is_armv7 and llvm_features_from_tune). These indirectly influnce the build and should be excluded from the signatures directly as is done in other toolchain recipes, e.g.: 39bfa0dd32 recipes/*-cross recipes: ignore TARGET_ARCH sstate hash (From OE-Core rev: 72d67410e92207a98a801ddf0cb9f1297a752975) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: remove Rust version 1.51.0 toolchainRandy MacLeod2021-08-2613-1785/+0
| | | | | | | | | | We typically only have one version so remove the older rust toolchain. This also fixes a maintainers oe-selftest. (From OE-Core rev: d8ff9672d2686801d535a91fa28a92e38d8f0409) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust-common.inc: Fix build failure with qemuppc64.Vinay Kumar2021-08-261-0/+2
| | | | | | | | | | | | | The glibc build of "rust-hello-world" throws error in libstd-rs package. error: unrecognized arch "powerpc64le" in target specification The same got fixed by changing the arch to "powerpc64". (From OE-Core rev: 1a28dd447c248f6b7f0efd121160ac798e2abf0c) Signed-off-by: Vinay Kumar <vinay.m.engg@gmail.com> Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: update the README to conform to being in oe-coreRandy MacLeod2021-08-261-18/+7
| | | | | | | | | | Provide the full link to the meta-rust issue since the README is no longer part of meta-rust. (From OE-Core rev: 11cb8e67f356d4758c3aae0e5851a44256459e77) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: mv README.md to recipes-devtools/rust/README-rust.mdRandy MacLeod2021-08-261-0/+69
| | | | | | | | | Import the meta-rust/README.md but relocate and rename it. (From OE-Core rev: a36b43187f9b78c279bdbd0ee9c6f7063a0e7cc7) Signed-off-by: Randy MacLeod <Randy.MacLeod@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* rust: initial merge of most of meta-rustRandy MacLeod2021-08-2641-0/+4694
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>