compiler_builtins are now mandatory; Add them.

In rust-lang/rust@679657b863 a breaking
change was introduced that now requires compiler_builtins. Add them,
and use the opportunity to kick out rlibc, since memset() et al. can
be provided by compiler intrinsics.
pull/4/head
Andre Richter 6 years ago
parent 857568009e
commit 32ef64b36e

2
.gitignore vendored

@ -1 +1 @@
**/dockcross-linux-aarch64
**/dockcross-linux-aarch64

@ -0,0 +1,5 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
stage = 1

@ -0,0 +1,5 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
stage = 1

@ -0,0 +1,5 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
stage = 1

@ -3,7 +3,6 @@ name = "kernel8"
version = "0.1.0"
dependencies = [
"raspi3_glue 0.1.0",
"rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -11,11 +10,6 @@ dependencies = [
name = "raspi3_glue"
version = "0.1.0"
[[package]]
name = "rlibc"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "vcell"
version = "0.1.0"
@ -30,6 +24,5 @@ dependencies = [
]
[metadata]
"checksum rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc874b127765f014d792f16763a81245ab80500e2ad921ed4ee9e82481ee08fe"
"checksum vcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "45c297f0afb6928cd08ab1ff9d95e99392595ea25ae1b5ecf822ff8764e57a0d"
"checksum volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0d67cb4616d99b940db1d6bd28844ff97108b498a6ca850e5b6191a532063286"

@ -6,4 +6,3 @@ authors = ["Andre Richter <andre.o.richter@gmail.com>"]
[dependencies]
raspi3_glue = { path = "raspi3_glue" }
volatile-register = "0.2.0"
rlibc = "1.0"

@ -35,17 +35,15 @@ Where each tag looks like:
n+3. optional value buffer
```
### rlibc
### Xargo.toml
The mailbox buffer is a fixed array that is zero-initialized. To achieve
zero-initialization, Rust utilizies and links to the `memset()` function, which
is normally provided by `libc`.
Since we are writing a `no_std` crate, we need to explicitly provide it. The
easiest way is pulling in [rlibc] by adding it as an `extern crate` to `main.rs`
and adding the dependency to `Cargo.toml`.
[rlibc]: https://github.com/alexcrichton/rlibc
easiest way is pulling in the `mem` feature of the `compiler_builtins` by adding
it to `Xargo.toml`.
### Synchronization

@ -0,0 +1,6 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
features = ["mem"] # for memset() et al.
stage = 1

Binary file not shown.

@ -26,7 +26,6 @@
#![feature(asm)]
extern crate raspi3_glue;
extern crate rlibc; // for memset et al.b
extern crate volatile_register;
const MMIO_BASE: u32 = 0x3F00_0000;

@ -3,7 +3,6 @@ name = "kernel8"
version = "0.1.0"
dependencies = [
"raspi3_glue 0.1.0",
"rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -11,11 +10,6 @@ dependencies = [
name = "raspi3_glue"
version = "0.1.0"
[[package]]
name = "rlibc"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "vcell"
version = "0.1.0"
@ -30,6 +24,5 @@ dependencies = [
]
[metadata]
"checksum rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc874b127765f014d792f16763a81245ab80500e2ad921ed4ee9e82481ee08fe"
"checksum vcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "45c297f0afb6928cd08ab1ff9d95e99392595ea25ae1b5ecf822ff8764e57a0d"
"checksum volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0d67cb4616d99b940db1d6bd28844ff97108b498a6ca850e5b6191a532063286"

@ -6,4 +6,3 @@ authors = ["Andre Richter <andre.o.richter@gmail.com>"]
[dependencies]
raspi3_glue = { path = "raspi3_glue" }
volatile-register = "0.2.0"
rlibc = "1.0"

@ -0,0 +1,6 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
features = ["mem"] # for memset() et al.
stage = 1

Binary file not shown.

@ -26,7 +26,6 @@
#![feature(asm)]
extern crate raspi3_glue;
extern crate rlibc; // for memset et al.b
extern crate volatile_register;
const MMIO_BASE: u32 = 0x3F00_0000;

@ -3,7 +3,6 @@ name = "kernel8"
version = "0.1.0"
dependencies = [
"raspi3_glue 0.1.0",
"rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
"volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -11,11 +10,6 @@ dependencies = [
name = "raspi3_glue"
version = "0.1.0"
[[package]]
name = "rlibc"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "vcell"
version = "0.1.0"
@ -30,6 +24,5 @@ dependencies = [
]
[metadata]
"checksum rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc874b127765f014d792f16763a81245ab80500e2ad921ed4ee9e82481ee08fe"
"checksum vcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "45c297f0afb6928cd08ab1ff9d95e99392595ea25ae1b5ecf822ff8764e57a0d"
"checksum volatile-register 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0d67cb4616d99b940db1d6bd28844ff97108b498a6ca850e5b6191a532063286"

@ -6,4 +6,3 @@ authors = ["Andre Richter <andre.o.richter@gmail.com>"]
[dependencies]
raspi3_glue = { path = "raspi3_glue" }
volatile-register = "0.2.0"
rlibc = "1.0"

@ -0,0 +1,6 @@
[dependencies.core]
stage = 0
[dependencies.compiler_builtins]
features = ["mem"] # for memset() et al.
stage = 1

Binary file not shown.

@ -26,7 +26,6 @@
#![feature(asm)]
extern crate raspi3_glue;
extern crate rlibc; // for memset et al.b
extern crate volatile_register;
const MMIO_BASE: u32 = 0x3F00_0000;

Loading…
Cancel
Save