Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cargo.toml: Streamline profile configuration #180

Merged
merged 3 commits into from
Nov 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,3 @@ members = [
"examples/demo",
]
exclude = ["target", "loader", "libhermit-rs"]

[profile.release]
opt-level = 2
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled
6 changes: 0 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,6 @@ Consequently, it is required to **extend** *Cargo.toml* with following lines:

[target.'cfg(target_os = "hermit")'.dependencies]
hermit-sys = "0.1.*"

[profile.release]
opt-level = 3

[profile.dev]
opt-level = 1
```

To link the application with RustyHermit, declare `hermit_sys` an `external crate` in the main file of your application.
Expand Down
15 changes: 0 additions & 15 deletions benches/micro/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,3 @@ acpi = ["hermit-sys/acpi"]
fsgsbase = ["hermit-sys/fsgsbase"]
smp = ["hermit-sys/smp"]
instrument = ["hermit-sys/instrument"]

[profile.release]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled
15 changes: 0 additions & 15 deletions benches/netbench/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,18 +45,3 @@ path = "src/rust-tcp-latency/server.rs"
[[bin]]
name = "client-latency"
path = "src/rust-tcp-latency/client.rs"

[profile.release]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled
15 changes: 0 additions & 15 deletions examples/demo/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,3 @@ acpi = ["hermit-sys/acpi"]
fsgsbase = ["hermit-sys/fsgsbase"]
smp = ["hermit-sys/smp"]
instrument = ["hermit-sys/instrument"]

[profile.release]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled
15 changes: 0 additions & 15 deletions examples/hello_world/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,3 @@ acpi = ["hermit-sys/acpi"]
fsgsbase = ["hermit-sys/fsgsbase"]
smp = ["hermit-sys/smp"]
instrument = ["hermit-sys/instrument"]

[profile.release]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled
15 changes: 0 additions & 15 deletions examples/httpd/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,3 @@ fsgsbase = ["hermit-sys/fsgsbase"]
smp = ["hermit-sys/smp"]
smoltcp = ["hermit-sys/smoltcp"]
instrument = ["hermit-sys/instrument"]

[profile.release]
opt-level = 3
debug = false
rpath = false
lto = false
debug-assertions = false

[profile.dev]
opt-level = 1 # controls the `--opt-level` the compiler builds with
debug = true # controls whether the compiler passes `-C debuginfo`
# a value of `true` is equivalent to `2`
rpath = false # controls whether the compiler passes `-C rpath`
lto = false # controls `-C lto` for binaries and staticlibs
debug-assertions = true # controls whether debug assertions are enabled