Cargo-image

Crates.io maintenance-as-is

An alternative to bootimage that doesn't use cargo-xbuild.

Intended to be used with cargo-sysroot, this tool will create an image bootable in QEMU for you, using the bootloader crate.

Details

Unlike bootimage, the standard cargo-build command is used to build your kernel.

It is expected that your .cargo/config be configured to pass --sysroot and have a proper target, such as by using cargo-sysroot.

Prerequisite

An example .cargo/config might look like this. These are the absolute minimum settings required for cargo-image to work.

cargo-sysroot will automatically set this up for you, if you use it. cargo-sysroot is not a requirement.

rust [build] target = "path/to/your/target/specification/json" rustflags = [ "--sysroot", "full/path/to/target/sysroot", ]

FAQ

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.