aboutsummaryrefslogtreecommitdiff
path: root/src/link.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2022-01-26 14:59:15 -0700
committerAndrew Kelley <andrew@ziglang.org>2022-01-26 15:01:59 -0700
commit40c9ce2caf8f024a249b3524813eb495cf1341b3 (patch)
tree84dd4cfca306b33956746650155dd14d4e4fafac /src/link.zig
parent35503b3d3fe1bfce19f1ea3e78a75ce87b0ed646 (diff)
downloadzig-40c9ce2caf8f024a249b3524813eb495cf1341b3.tar.gz
zig-40c9ce2caf8f024a249b3524813eb495cf1341b3.zip
zig cc: add --hash-style linker parameter
This is only relevant for ELF files. I also fixed a bug where passing a zig source file to `zig cc` would incorrectly punt to clang because it thought there were no positional arguments.
Diffstat (limited to 'src/link.zig')
-rw-r--r--src/link.zig3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/link.zig b/src/link.zig
index 817cb4c052..883d79de34 100644
--- a/src/link.zig
+++ b/src/link.zig
@@ -146,6 +146,7 @@ pub const Options = struct {
disable_lld_caching: bool,
is_test: bool,
use_stage1: bool,
+ hash_style: HashStyle,
major_subsystem_version: ?u32,
minor_subsystem_version: ?u32,
gc_sections: ?bool = null,
@@ -191,6 +192,8 @@ pub const Options = struct {
}
};
+pub const HashStyle = enum { sysv, gnu, both };
+
pub const File = struct {
tag: Tag,
options: Options,