Nick Rirush
6 years ago
commit
a29fffe302
6 changed files with 194 additions and 0 deletions
@ -0,0 +1,2 @@ |
|||||
|
/target |
||||
|
**/*.rs.bk |
@ -0,0 +1,136 @@ |
|||||
|
[[package]] |
||||
|
name = "bit_field" |
||||
|
version = "0.9.0" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "bitflags" |
||||
|
version = "1.0.4" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "cfg-if" |
||||
|
version = "0.1.6" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "coonboot" |
||||
|
version = "0.1.0" |
||||
|
dependencies = [ |
||||
|
"uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-alloc 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-exts 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-logger 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-services 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "log" |
||||
|
version = "0.4.5" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
dependencies = [ |
||||
|
"cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "os_bootinfo" |
||||
|
version = "0.2.1" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "rlibc" |
||||
|
version = "1.0.0" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "ucs2" |
||||
|
version = "0.1.0" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "uefi" |
||||
|
version = "0.1.0" |
||||
|
source = "git+https://github.com/GabrielMajeri/uefi-rs#efacc77ebe2d62c23a06634bb28ed40d380005ca" |
||||
|
dependencies = [ |
||||
|
"bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"ucs2 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "uefi-alloc" |
||||
|
version = "0.1.0" |
||||
|
source = "git+https://github.com/GabrielMajeri/uefi-rs#efacc77ebe2d62c23a06634bb28ed40d380005ca" |
||||
|
dependencies = [ |
||||
|
"uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "uefi-exts" |
||||
|
version = "0.1.0" |
||||
|
source = "git+https://github.com/GabrielMajeri/uefi-rs#efacc77ebe2d62c23a06634bb28ed40d380005ca" |
||||
|
dependencies = [ |
||||
|
"uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-services 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "uefi-logger" |
||||
|
version = "0.1.0" |
||||
|
source = "git+https://github.com/GabrielMajeri/uefi-rs#efacc77ebe2d62c23a06634bb28ed40d380005ca" |
||||
|
dependencies = [ |
||||
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "uefi-services" |
||||
|
version = "0.1.0" |
||||
|
source = "git+https://github.com/GabrielMajeri/uefi-rs#efacc77ebe2d62c23a06634bb28ed40d380005ca" |
||||
|
dependencies = [ |
||||
|
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-alloc 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"uefi-logger 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)", |
||||
|
"x86_64 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
] |
||||
|
|
||||
|
[[package]] |
||||
|
name = "usize_conversions" |
||||
|
version = "0.2.0" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "ux" |
||||
|
version = "0.1.2" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
|
||||
|
[[package]] |
||||
|
name = "x86_64" |
||||
|
version = "0.2.14" |
||||
|
source = "registry+https://github.com/rust-lang/crates.io-index" |
||||
|
dependencies = [ |
||||
|
"bit_field 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"os_bootinfo 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"usize_conversions 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
"ux 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", |
||||
|
] |
||||
|
|
||||
|
[metadata] |
||||
|
"checksum bit_field 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ed8765909f9009617974ab6b7d332625b320b33c326b1e9321382ef1999b5d56" |
||||
|
"checksum bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "228047a76f468627ca71776ecdebd732a3423081fcf5125585bcd7c49886ce12" |
||||
|
"checksum cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "082bb9b28e00d3c9d39cc03e64ce4cea0f1bb9b3fde493f0cbc008472d22bdf4" |
||||
|
"checksum log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "d4fcce5fa49cc693c312001daf1d13411c4a5283796bac1084299ea3e567113f" |
||||
|
"checksum os_bootinfo 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "66481dbeb5e773e7bd85b63cd6042c30786f834338288c5ec4f3742673db360a" |
||||
|
"checksum rlibc 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc874b127765f014d792f16763a81245ab80500e2ad921ed4ee9e82481ee08fe" |
||||
|
"checksum ucs2 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8e583483194b07714e09e7f72ae3ed447d17fe6855f66a2ccbf6751e52df82e0" |
||||
|
"checksum uefi 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)" = "<none>" |
||||
|
"checksum uefi-alloc 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)" = "<none>" |
||||
|
"checksum uefi-exts 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)" = "<none>" |
||||
|
"checksum uefi-logger 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)" = "<none>" |
||||
|
"checksum uefi-services 0.1.0 (git+https://github.com/GabrielMajeri/uefi-rs)" = "<none>" |
||||
|
"checksum usize_conversions 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f70329e2cbe45d6c97a5112daad40c34cd9a4e18edb5a2a18fefeb584d8d25e5" |
||||
|
"checksum ux 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "53d8df5dd8d07fedccd202de1887d94481fadaea3db70479f459e8163a1fab41" |
||||
|
"checksum x86_64 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)" = "2bd647af1614659e1febec1d681231aea4ebda4818bf55a578aff02f3e4db4b4" |
@ -0,0 +1,11 @@ |
|||||
|
[package] |
||||
|
name = "coonboot" |
||||
|
version = "0.1.0" |
||||
|
authors = ["rirush"] |
||||
|
|
||||
|
[dependencies] |
||||
|
uefi = { git = "https://github.com/GabrielMajeri/uefi-rs" } |
||||
|
uefi-alloc = { git = "https://github.com/GabrielMajeri/uefi-rs" } |
||||
|
uefi-exts = { git = "https://github.com/GabrielMajeri/uefi-rs" } |
||||
|
uefi-logger = { git = "https://github.com/GabrielMajeri/uefi-rs" } |
||||
|
uefi-services = { git = "https://github.com/GabrielMajeri/uefi-rs" } |
@ -0,0 +1 @@ |
|||||
|
nightly |
@ -0,0 +1,18 @@ |
|||||
|
#![no_std] |
||||
|
#![no_main] |
||||
|
|
||||
|
extern crate uefi; |
||||
|
extern crate uefi_alloc; |
||||
|
extern crate uefi_services; |
||||
|
extern crate uefi_exts; |
||||
|
extern crate uefi_logger; |
||||
|
|
||||
|
use uefi::prelude::*; |
||||
|
|
||||
|
#[no_mangle] |
||||
|
pub extern "win64" fn uefi_start(image: uefi::Handle, table: SystemTable<Boot>) -> Status { |
||||
|
uefi_services::init(&table).expect_success("Unable to initialize utilities"); |
||||
|
table.stdout().reset(false).expect_success("Failed to reset stdout"); |
||||
|
|
||||
|
Status::SUCCESS |
||||
|
} |
@ -0,0 +1,26 @@ |
|||||
|
{ |
||||
|
"llvm-target": "x86_64-pc-windows-gnu", |
||||
|
"env": "gnu", |
||||
|
"target-family": "windows", |
||||
|
"target-endian": "little", |
||||
|
"target-pointer-width": "64", |
||||
|
"target-c-int-width": "32", |
||||
|
"os": "uefi", |
||||
|
"arch": "x86_64", |
||||
|
"data-layout": "e-m:e-i64:64-f80:128-n8:16:32:64-S128", |
||||
|
"linker": "rust-lld", |
||||
|
"linker-flavor": "lld-link", |
||||
|
"pre-link-args": { |
||||
|
"lld-link": [ |
||||
|
"/Subsystem:EFI_Application", |
||||
|
"/Entry:uefi_start" |
||||
|
] |
||||
|
}, |
||||
|
"panic-strategy": "abort", |
||||
|
"default-hidden-visibility": true, |
||||
|
"executables": true, |
||||
|
"position-independent-executables": true, |
||||
|
"exe-suffix": ".efi", |
||||
|
"is-like-windows": true, |
||||
|
"emit-debug-gdb-scripts": false |
||||
|
} |
Loading…
Reference in new issue