diff --git a/Cargo.toml b/Cargo.toml index 58f4091..3cd725f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,3 +1,5 @@ +cargo-features = ["profile-rustflags"] + [package] name = "itop" description = "top program, made in iced" @@ -13,6 +15,23 @@ sysinfo = "0.39.6" version = "0.14.0" features = [ "canvas", "smol" ] +[profile.debug] +debug = true +strip = "none" +debug-assertions = true +overflow-checks = true + +[profile.dev] +opt-level = 3 +rustflags = ["-Clink-arg=-fuse-ld=mold"] + +debug = false +strip = "debuginfo" +debug-assertions = false +overflow-checks = false + [profile.release] -lto = true +panic = "abort" codegen-units = 1 +lto = true +strip = "symbols" diff --git a/flake.nix b/flake.nix index 1c9efff..e17d2c2 100644 --- a/flake.nix +++ b/flake.nix @@ -104,7 +104,10 @@ LD_LIBRARY_PATH = lib.makeLibraryPath dlDeps; inputsFrom = [ crate ]; - packages = [ pkgs.rust-analyzer ]; + packages = with pkgs; [ + rust-analyzer + mold + ]; }; } );