Skip to content

Commit 1a5dcff

Browse files
committed
std.Build: update build-id flag description
it now denotes: - all supported styles - what a given style outputs - what formats a given style supports
1 parent 013a228 commit 1a5dcff

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

lib/compiler/build_runner.zig

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1373,10 +1373,13 @@ fn usage(b: *std.Build, out_stream: anytype) !void {
13731373
\\ --zig-lib-dir [arg] Override path to Zig lib directory
13741374
\\ --build-runner [file] Override path to build runner
13751375
\\ --seed [integer] For shuffling dependency traversal order (default: random)
1376-
\\ --build-id[=style] At a minor link-time expense, coordinates stripped binaries
1377-
\\ fast, uuid, sha1, md5 with debug symbols via a '.note.gnu.build-id' section
1378-
\\ 0x[hexstring] Maximum 32 bytes
1379-
\\ none (default) Disable build-id
1376+
\\ --build-id[=style] At a minor link-time expense, embeds a build ID in binaries
1377+
\\ fast 8-byte non-cryptographic hash (COFF, ELF, WASM)
1378+
\\ sha1, tree 20-byte cryptographic hash (ELF, WASM)
1379+
\\ md5 16-byte cryptographic hash (ELF)
1380+
\\ uuid 16-byte random UUID (ELF, WASM)
1381+
\\ 0x[hexstring] Constant ID, maximum 32 bytes (ELF, WASM)
1382+
\\ none (default) No build ID
13801383
\\ --debug-log [scope] Enable debugging the compiler
13811384
\\ --debug-pkg-config Fail if unknown pkg-config flags encountered
13821385
\\ --debug-rt Debug compiler runtime libraries

src/main.zig

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -570,10 +570,13 @@ const usage_build_generic =
570570
\\ -fno-allow-shlib-undefined Disallows undefined symbols in shared libraries
571571
\\ -fallow-so-scripts Allows .so files to be GNU ld scripts
572572
\\ -fno-allow-so-scripts (default) .so files must be ELF files
573-
\\ --build-id[=style] At a minor link-time expense, coordinates stripped binaries
574-
\\ fast, uuid, sha1, md5 with debug symbols via a '.note.gnu.build-id' section
575-
\\ 0x[hexstring] Maximum 32 bytes
576-
\\ none (default) Disable build-id
573+
\\ --build-id[=style] At a minor link-time expense, embeds a build ID in binaries
574+
\\ fast 8-byte non-cryptographic hash (COFF, ELF, WASM)
575+
\\ sha1, tree 20-byte cryptographic hash (ELF, WASM)
576+
\\ md5 16-byte cryptographic hash (ELF)
577+
\\ uuid 16-byte random UUID (ELF, WASM)
578+
\\ 0x[hexstring] Constant ID, maximum 32 bytes (ELF, WASM)
579+
\\ none (default) No build ID
577580
\\ --eh-frame-hdr Enable C++ exception handling by passing --eh-frame-hdr to linker
578581
\\ --no-eh-frame-hdr Disable C++ exception handling by passing --no-eh-frame-hdr to linker
579582
\\ --emit-relocs Enable output of relocation sections for post build tools

0 commit comments

Comments
 (0)