Commit Graph

853 Commits

Author SHA1 Message Date
Reto Schneider 25ee517ae2 rust: Add support for ARMv5 (#342)
At GARDENA, we are running our Rust based web interface and
overlayfs-purge tool successfully on our ARMv5, Atmel SAM9G25 SoC based
IoT gateway.
2021-04-24 16:54:42 -04:00
Anatol Belski 920db7b045 workflows: Refactor yml to improve build time (#335)
* workflows: Refactor yml to improve build time and reduce size

- Split out the build configuration job
- Use the official sstate mirror
- Disable more of unnecessary features

Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-04-04 20:53:28 -04:00
Steven Walter 0048ea8253 Merge pull request #333 from weltling/sdk_ci
workflows: Build and test SDK
2021-04-03 19:20:26 -04:00
Anatol Belski e0180c565e workflows: Further reduce SDK size
Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-04-03 14:33:11 +02:00
Anatol Belski b637307219 workflows: Install SDK under the workspace path
Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-04-03 14:14:04 +02:00
Steven Walter 742cd5c095 Merge pull request #334 from meta-rust/progress
cargo.bbclass: support cargo's progress indicator
2021-04-02 18:04:11 -04:00
Steven Walter 53cbdb566d cargo.bbclass: support cargo's progress indicator
Recent versions of cargo support always showing the progress indicator.
By default the progress indicator is hidden if the output is not a tty.
For bitbake builds, the output is redirected to a file and not a tty.
However, if we tell cargo to always show the progress indicator, bitbake
can parse it and will show the user how the rust build is progressing.
2021-04-02 16:21:43 -04:00
Anatol Belski 2a9ee78d08 workflows: Check to reduce size
Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-04-02 19:50:49 +02:00
Anatol Belski 3638b7da88 workflows: Ensure project dir doesn't exist 2021-04-02 19:20:35 +02:00
Anatol Belski 08c385c922 workflows: Build and test SDK
Closes #332.

Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-04-02 16:59:41 +02:00
Steven Walter 2c89770123 Merge pull request #331 from YoeDistro/yoe/mut
rust-llvm: Update LLVM_RELEASE to accurate versions
2021-04-01 16:52:34 -04:00
Khem Raj d9e32f6288 rust-llvm: Update LLVM_RELEASE to accurate versions
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-04-01 08:44:46 -07:00
Anatol Belski 250230e292 Merge pull request #313 from weltling/nativesdk_0
nativesdk: Implement cross canadian support
2021-04-01 14:38:54 +02:00
Anatol Belski c06069fdaa cross-canadian: Sync with 1.51.0 addition for rustc and cargo
Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-03-30 15:13:28 +00:00
Anatol Belski e492b2d86f ident: Fix more WS issues 2021-03-30 15:11:59 +00:00
Anatol Belski 2932b399a5 packagegroup-rust-cross-canadian: Remove trailing WS 2021-03-30 15:11:59 +00:00
Anatol Belski ae08e553b8 rustc-cross-canadian: Remove obsolete comment 2021-03-30 15:11:59 +00:00
Anatol Belski 439dea8664 nativesdk: Implement cross canadian support
This addition closes #236 requesting the SDK support. The implementation
consists on a yet minimum set of worky functionality;

- Includes rustc, rustdoc and cargo.
- Includes libstd and accompanying lib archives for host and for target.
- Integrates with the standard environment setup script.
- Integrates configurations automatically build for target.

The supported build host is still AMD64 only.

Note that there's no need on introducing crosssdk package as the
official snapshot package serves same way as a non SDK build.

Possible future directions:

- Offline build:
	- Support pre-cached set of crates that can be vendored.
	- Support pre-filled cargo registry.
- Support further tools like cargo-fmt, cargo-clippy, GDB support and so
on.

Signed-off-by: Anatol Belski <anbelski@linux.microsoft.com>
2021-03-30 15:11:59 +00:00
Steven Walter a4302679bb Merge pull request #330 from YoeDistro/yoe/mut
Update rust to 1.51
2021-03-28 20:35:24 -04:00
Khem Raj 64c625f119 cargo/libstd-rs: Forward port musl/riscv support
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-03-28 15:55:12 -07:00
Colin Finck 191cd91817 Update to Rust 1.51.0 and remove 1.47.0
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-03-28 15:55:12 -07:00
Steven Walter da00d57cda Merge pull request #329 from srwalter/workflow
Enable a workflow to build rust-hello-world
2021-03-28 17:16:44 -04:00
Steven Walter 57a202ac53 workflows/main.yml: use bitbake-layers command instead of sed 2021-03-28 15:25:44 -04:00
Cody Schafer 51eba75155 Merge pull request #325 from janderholm/enable-profiler-runtime
rust.inc: Build the profiler runtime
2021-03-28 15:05:51 -04:00
Steven Walter 33904e6514 Enable a workflow to build rust-hello-world
Verify that rust-hello-world build (which in turn ensures that
rust-native, cargo-native, etc all build)
2021-03-27 23:47:07 -04:00
Khem Raj 0fffd992ee Merge pull request #326 from YoeDistro/yoe/mut
layer.conf: add hardknott to compatible release branches
2021-03-18 11:52:23 -07:00
Khem Raj 7a8876558b layer.conf: add hardknott to compatible release branches
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-03-17 23:16:15 -07:00
Johan Anderholm cb5a599f02 rust.inc: Build the profiler runtime
Needed when compiling with options such as "-C profile-generate" or
"-Z instrument-coverage", e.g. when generating coverage reports or doing
profile guided optimization.
2021-03-16 14:15:32 +01:00
Cody Schafer 9a035fe272 Merge pull request #324 from YoeDistro/yoe/mut
rust-llvm: Fix build with gcc11
2021-03-02 20:19:55 -05:00
Khem Raj 013b210033 rust-llvm: Fix build with gcc11
Backport a patch from upstream llvm

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-03-02 11:09:06 -08:00
Khem Raj 3f3aa9a6bb Merge pull request #318 from YoeDistro/kraj/riscv-musl
add riscv musl support
2021-03-01 08:42:09 -08:00
Cody Schafer f31b044c53 Merge pull request #317 from YoeDistro/kraj/ppc64le
rust: Enable ppc64le target
2021-02-28 13:36:22 -05:00
Cody Schafer 30dcb2d61f Merge pull request #323 from jwinarske/example-install
install example executables
2021-02-27 13:11:05 -05:00
Colin Finck 6f399bbd90 Merge pull request #319 from ColinFinck/fix/llvm-cpu
Revamp llvm_cpu to select the closest CPU for optimization.
2021-02-26 14:07:40 +01:00
Colin Finck 81f9357b58 Remove mips/mipsel translation to mips32, which is the same as "generic" 2021-02-24 12:13:18 +01:00
Colin Finck 7a261d5d14 Merge pull request #320 from ColinFinck/remove-old-rust-version-checks
Remove checks for Rust versions we don't build anymore.
2021-02-24 09:37:43 +01:00
Joel Winarske 81a4d79c06 install example executables 2021-02-23 20:03:59 -08:00
Colin Finck f8b9103477 Remove checks for Rust versions we don't build anymore. 2021-02-23 17:54:26 +01:00
Colin Finck 83ad3d415f Revamp llvm_cpu to select the closest CPU for optimization. 2021-02-23 16:32:55 +01:00
Khem Raj 38a017d9de rust: Enable ppc64le target
this helps building the compiler, work is still needed for libstd-rs and
other pieces

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-02-20 13:04:07 -08:00
Khem Raj 4434790fc2 libstd-rs/libc: Backport riscv64/musl support
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-02-17 21:56:19 -08:00
Khem Raj c1e1921e03 rust/cargo/libstd-rs: Add riscv/musl support
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2021-02-17 21:56:19 -08:00
Cody Schafer 029f1ea6a6 Merge pull request #312 from janderholm/no-target-in-rust-native
rust-native shouldn't depend on TARGET variables
2021-02-18 03:22:47 +00:00
Cody Schafer 9937659804 Merge pull request #310 from BeneSim/fix-cargo-src-dir
Factor in `CARGO_SRC_DIR` when setting `MANIFEST_PATH`.
2021-02-18 03:21:53 +00:00
Johan Anderholm 920328c8d8 rust-native shouldn't depend on TARGET variables
Similar to 3b783652cc, this makes sure
rust-native does not depend on target variables. This allow one
rust-native to be shared between machines of different architectures
again.

For the record, the following guide was used to find out why
do_rust_gen_targets differed between different machines.
https://wiki.yoctoproject.org/wiki/TipsAndTricks/Understanding_what_changed_(diffsigs_etc)
2021-02-16 19:49:46 +01:00
Benjamin Isbarn 4e96013677 Factor in CARGO_SRC_DIR when setting MANIFEST_PATH. 2021-02-15 14:36:46 +01:00
Cody Schafer 341a3c77bb Merge pull request #305 from akiernan/master
rust: Drop v8.1a tune for aarch64
2021-02-09 16:04:19 +00:00
Cody Schafer d59c590245 Merge pull request #306 from ColinFinck/remove-old-versions
Keep only the most recent two Rust versions.
2021-02-09 16:01:42 +00:00
Colin Finck 87e8d50abd Keep only the most recent two Rust versions.
Older ones are already unbuildable and nobody misses them, see https://github.com/meta-rust/meta-rust/issues/298
2021-02-09 15:09:14 +01:00
Alex Kiernan 53c9aabda3 rust: Drop v8.1a tune for aarch64
Building for "+v8.1a"  breaks on (at least) Cortex A53 (Armv8-A) on
startup with `Illegal instruction`.

Fixes: 26609f46d9 ("rust.inc: use 'v8.1a' feature when building for aarch64 instead of 'v8'")
2021-02-09 03:13:25 +00:00