From 9206d9ff7b4137535256862fab4050d77f2c0431 Mon Sep 17 00:00:00 2001 From: Hiroshi Shinaoka Date: Sat, 8 Aug 2026 19:14:12 +0200 Subject: [PATCH] build: drop full debug info from default profiles Local target/ reached 14 GB, 12 GB of it release artifacts, because [profile.release] carried debug = true while repository policy runs the normal verification suite in release mode. Release now uses line-tables-only, which keeps file:line RUST_BACKTRACE output; a new release-debug profile inherits release with full debug info for debugger sessions. dev/test pin debug = 0 while keeping debug assertions and overflow checks, matching the shared build-artifact hygiene rule (tensor4all/tensor4all-agent-rules#9) and tenferro-rs practice. Co-Authored-By: Claude Fable 5 --- Cargo.toml | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index bc1d69a3..5ada6726 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -29,8 +29,26 @@ authors = ["tensor4all collaboration"] license = "MIT" repository = "https://github.com/tensor4all/tensor4all-rs" +# Keep default profiles free of full debug info (shared rule: build-artifact +# hygiene). Line tables preserve readable RUST_BACKTRACE file:line output. +# For full debugger info, build with --profile release-debug, or override one +# command with CARGO_PROFILE_DEV_DEBUG=2 / CARGO_PROFILE_TEST_DEBUG=2. +[profile.dev] +debug = 0 +debug-assertions = true +overflow-checks = true + +[profile.test] +debug = 0 +debug-assertions = true +overflow-checks = true + [profile.release] -debug = true # Include debug info in release builds (enables detailed RUST_BACKTRACE) +debug = "line-tables-only" + +[profile.release-debug] +inherits = "release" +debug = true [workspace.dependencies] num-complex = "0.4"