mirror of
https://github.com/dexoron/dcr.git
synced 2026-10-21 14:08:30 +00:00
feat(build): add freestanding, lto, strip, panic-abort, and codegen-units support in dcr.toml
This commit is contained in:
@@ -20,6 +20,10 @@ DCR supports 4 compilation backends. Selection is automatic based on file extens
|
||||
- Compiler resolved via `resolve_compiler()`: `DCR_COMPILER` > `DCR_CC` > `[toolchain]` > `build.compiler` > `PATH`
|
||||
- Supports `.d` files for header dependency tracking
|
||||
- Flags: `-std=`, `-MMD -MF`, `-c -o`, `-I`, `-L`, `-l`
|
||||
- Conditional flags based on config:
|
||||
- `freestanding` or bare-metal target: `-ffreestanding` (compile), `-nostdlib -static` (link)
|
||||
- `lto`: `-flto` (compile + link)
|
||||
- `panic = "abort"`: `-fno-exceptions` (C++ only), `-fno-unwind-tables`, `-fno-asynchronous-unwind-tables`
|
||||
|
||||
### MSVC
|
||||
|
||||
|
||||
Reference in New Issue
Block a user