mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-20 07:57:49 +00:00
Add rustc-abi field to target spec JSON
The Rust compiler now requires an explicit `rustc-abi: x86-softfloat` field when using the soft-float target feature. This was added in https://github.com/rust-lang/rust/pull/136146 and is part of the latest nightlies.
I updated the post branches in commit 688a21e4
This commit is contained in:
@@ -194,6 +194,12 @@ Un problème avec la désactivation de SIMD est que les opérations sur les nomb
|
||||
|
||||
Pour plus d'informations, voir notre article sur la [désactivation de SIMD](@/edition-2/posts/02-minimal-rust-kernel/disable-simd/index.md).
|
||||
|
||||
```json
|
||||
"rustc-abi": "x86-softfloat"
|
||||
```
|
||||
|
||||
As we want to use the `soft-float` feature, we also need to tell the Rust compiler `rustc` that we want to use the corresponding ABI. We can do that by setting the `x86-softfloat` field to `x86-softfloat`.
|
||||
|
||||
#### Assembler le tout
|
||||
Notre fichier de spécification de cible ressemble maintenant à ceci :
|
||||
|
||||
@@ -211,7 +217,8 @@ Notre fichier de spécification de cible ressemble maintenant à ceci :
|
||||
"linker": "rust-lld",
|
||||
"panic-strategy": "abort",
|
||||
"disable-redzone": true,
|
||||
"features": "-mmx,-sse,+soft-float"
|
||||
"features": "-mmx,-sse,+soft-float",
|
||||
"rustc-abi": "x86-softfloat"
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user