Skip to content

Commit

Permalink
[Opt] project structure refactored
Browse files Browse the repository at this point in the history
  • Loading branch information
M4tsuri committed Oct 18, 2021
1 parent ec22ccf commit 3d28858
Show file tree
Hide file tree
Showing 22 changed files with 34 additions and 13 deletions.
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/target
**/target
.gdb_history
**/.gdb_history
.DS_Store
**/.DS_Store
.gdbinit
**/.gdbinit
5 changes: 0 additions & 5 deletions bootloader/.gitignore

This file was deleted.

2 changes: 1 addition & 1 deletion bootloader/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
layout = { path = "src/bios/layout" }
layout = { path = "./src/bios/layout" }

[build-dependencies]
llvm-tools = "0.1.1"
Expand Down
2 changes: 1 addition & 1 deletion bootloader/src/bios/stage_1/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
i386 = { path = "../i386" }
i386 = { path = "../../../../i386" }
layout = { path = "../layout" }
2 changes: 1 addition & 1 deletion bootloader/src/bios/stage_2/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
i386 = { path = "../i386" }
i386 = { path = "../../../../i386" }
layout = { path = "../layout" }
2 changes: 1 addition & 1 deletion bootloader/src/bios/stage_3/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
i386 = { path = "../i386" }
i386 = { path = "../../../../i386" }
layout = { path = "../layout" }
2 changes: 1 addition & 1 deletion bootloader/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::{fs::File, io::{Read, Write}, path::Path};
use layout::*;

static MINEFEST_PATH: &str = "/Users/ctsinon/Projects/Orangs/bootloader";
static MINEFEST_PATH: &str = "/Users/ctsinon/Projects/Orangs/OrustS/bootloader";

static STAGES: [(&str, usize); 3] = [
(&"target/stage_1/target/release/stage_1.bin", STAGE1_SIZE),
Expand Down
File renamed without changes.
10 changes: 10 additions & 0 deletions i386/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[package]
name = "i386"
version = "0.1.0"
edition = "2018"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
layout = { path = "../bootloader/src/bios/layout" }

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
7 changes: 7 additions & 0 deletions kernel/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions bootloader/src/bios/i386/Cargo.toml → kernel/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
[package]
name = "i386"
name = "kernel"
version = "0.1.0"
edition = "2018"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
layout = { path = "../layout" }

3 changes: 3 additions & 0 deletions kernel/src/main.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fn main() {
println!("Hello, world!");
}

0 comments on commit 3d28858

Please sign in to comment.