The test TestRust is currently broken with ripgrep package with the following error: error[E0514]: found crate `core` compiled by an incompatible version of rustc | = help: please recompile that crate using this compiler (rustc 1.58.1) (consider running `cargo clean` first) = note: the following crate versions were found: crate `core` compiled by rustc 1.58.1 (db9d1b20b 2022-01-20): TestRust/host/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-6cfcec236d576603.rlib error[E0514]: found crate `std` compiled by an incompatible version of rustc The problem is not really a cross-compilation issue (we are building for an armv7 target on x86_64 host) but a problem with rust-std libraries (rlib). We can notice that "rustc 1.58.1 (db9d1b20b 2022-01-20)" is the same version as the prebuilt rustc used to bootstrap the build: TestRust/host/bin/rustc --version rustc 1.58.1 TestRustBin/host/bin/rustc --version rustc 1.58.1 (db9d1b20b 2022-01-20) Indeed we are using host-rust-bin to bootstrap the host-rust compiler package built by Buildroot. The problem is that the libcore-6cfcec236d576603.rlib file come from host-rust-bin (rust-std) and is not removed before installing host-rust built by Buildroot. We actually spent a lot of time to build host-rust with rust-std and forget to install this important library HOST_DIR. Looking at the host-rust build directory we can notice two installer script "install.sh" (the same scripts used to install host-rust-bin): TestRust/build/host-rust-1.58.1/build/tmp/tarball/rust/x86_64-unknown-linux-gnu/rust-1.58.1-x86_64-unknown-linux-gnu/install.sh TestRust/build/host-rust-1.58.1/build/tmp/tarball/rust-std/armv7-unknown-linux-gnueabihf/rust-std-1.58.1-armv7-unknown-linux-gnueabihf/install.sh The "tarball" directory is generated by the "python x.py dist" during the install step, we have to keep it. Replace "python x.py install" by theses two install scripts. Installing rust-std with the install.sh script replace the rust-std libraries installed by host-rust-bin. Fixes: https://gitlab.com/buildroot.org/buildroot/-/jobs/2116202544 Signed-off-by: Romain Naour <romain.naour@gmail.com> Cc: Eric Le Bihan <eric.le.bihan.dev@free.fr> [Arnout: remove redundant parenthesis; only use a variable for the common install opts] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> |
||
---|---|---|
arch | ||
board | ||
boot | ||
configs | ||
docs | ||
fs | ||
linux | ||
package | ||
support | ||
system | ||
toolchain | ||
utils | ||
.clang-format | ||
.defconfig | ||
.flake8 | ||
.gitignore | ||
.gitlab-ci.yml | ||
CHANGES | ||
Config.in | ||
Config.in.legacy | ||
COPYING | ||
DEVELOPERS | ||
Makefile | ||
Makefile.legacy | ||
README |
Buildroot is a simple, efficient and easy-to-use tool to generate embedded Linux systems through cross-compilation. The documentation can be found in docs/manual. You can generate a text document with 'make manual-text' and read output/docs/manual/manual.text. Online documentation can be found at http://buildroot.org/docs.html To build and use the buildroot stuff, do the following: 1) run 'make menuconfig' 2) select the target architecture and the packages you wish to compile 3) run 'make' 4) wait while it compiles 5) find the kernel, bootloader, root filesystem, etc. in output/images You do not need to be root to build or run buildroot. Have fun! Buildroot comes with a basic configuration for a number of boards. Run 'make list-defconfigs' to view the list of provided configurations. Please feed suggestions, bug reports, insults, and bribes back to the buildroot mailing list: buildroot@buildroot.org You can also find us on #buildroot on OFTC IRC. If you would like to contribute patches, please read https://buildroot.org/manual.html#submitting-patches