mirror of
https://github.com/nim-lang/Nim.git
synced 2026-06-03 10:24:44 +00:00
Add build-id=none for GCC when build for Release (#21808)
* Add build-id=none to GCC/Clang, unneeded metadata in binaries * Add build-id=none to GCC/Clang, unneeded metadata in binaries * Add build-id=none to Clang * Fix * Fix * Add build-id=none to GCC
This commit is contained in:
@@ -454,6 +454,7 @@
|
||||
static libraries.
|
||||
|
||||
- When compiling for Release the flag `-fno-math-errno` is used for GCC.
|
||||
- When compiling for Release the flag `--build-id=none` is used for GCC Linker.
|
||||
|
||||
## Docgen
|
||||
|
||||
|
||||
@@ -364,3 +364,9 @@ tcc.options.always = "-w"
|
||||
clang.options.linker %= "${clang.options.linker} -s"
|
||||
clang.cpp.options.linker %= "${clang.cpp.options.linker} -s"
|
||||
@end
|
||||
|
||||
# Linker: Skip "Build-ID metadata strings" in binaries when build for release.
|
||||
@if release or danger:
|
||||
gcc.options.linker %= "${gcc.options.linker} -Wl,--build-id=none"
|
||||
gcc.cpp.options.linker %= "${gcc.cpp.options.linker} -Wl,--build-id=none"
|
||||
@end
|
||||
|
||||
Reference in New Issue
Block a user