diff options
| author | Kenta Iwasaki <kenta@lithdew.net> | 2022-01-01 06:32:37 +0900 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2022-01-19 11:22:10 -0700 |
| commit | 5ae3e4e9bd5216c7cc2305c8996ed413c89c59e7 (patch) | |
| tree | fc0a9852022f89d33d249540527296e7477e7f19 /src/Compilation.zig | |
| parent | beb7495e19d23b4814e16772888e80688ad10e47 (diff) | |
| download | zig-5ae3e4e9bd5216c7cc2305c8996ed413c89c59e7.tar.gz zig-5ae3e4e9bd5216c7cc2305c8996ed413c89c59e7.zip | |
lld: allow for entrypoint symbol name to be set
This commit enables for the entrypoint symbol to be set when linking ELF
or WebAssembly modules with lld using the Zig compiler.
Diffstat (limited to 'src/Compilation.zig')
| -rw-r--r-- | src/Compilation.zig | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig index c21bf71326..2c64657903 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -791,6 +791,7 @@ pub const InitOptions = struct { /// infinite recursion. skip_linker_dependencies: bool = false, parent_compilation_link_libc: bool = false, + entry: ?[]const u8 = null, stack_size_override: ?u64 = null, image_base_override: ?u64 = null, self_exe_path: ?[]const u8 = null, @@ -1572,6 +1573,7 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation { .linker_optimization = linker_optimization, .major_subsystem_version = options.major_subsystem_version, .minor_subsystem_version = options.minor_subsystem_version, + .entry = options.entry, .stack_size_override = options.stack_size_override, .image_base_override = options.image_base_override, .include_compiler_rt = include_compiler_rt, |
