diff options
Diffstat (limited to 'src/Compilation.zig')
| -rw-r--r-- | src/Compilation.zig | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig index 687b0a6dc6..7ac1e49196 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -764,6 +764,7 @@ pub const InitOptions = struct { linker_z_noexecstack: bool = false, linker_z_now: bool = false, linker_z_relro: bool = false, + linker_z_nocopyreloc: bool = false, linker_tsaware: bool = false, linker_nxcompat: bool = false, linker_dynamicbase: bool = false, @@ -1597,6 +1598,7 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation { .z_notext = options.linker_z_notext, .z_defs = options.linker_z_defs, .z_origin = options.linker_z_origin, + .z_nocopyreloc = options.linker_z_nocopyreloc, .z_noexecstack = options.linker_z_noexecstack, .z_now = options.linker_z_now, .z_relro = options.linker_z_relro, @@ -2255,7 +2257,7 @@ fn prepareWholeEmitSubPath(arena: Allocator, opt_emit: ?EmitLoc) error{OutOfMemo /// to remind the programmer to update multiple related pieces of code that /// are in different locations. Bump this number when adding or deleting /// anything from the link cache manifest. -pub const link_hash_implementation_version = 2; +pub const link_hash_implementation_version = 3; fn addNonIncrementalStuffToCacheManifest(comp: *Compilation, man: *Cache.Manifest) !void { const gpa = comp.gpa; @@ -2265,7 +2267,7 @@ fn addNonIncrementalStuffToCacheManifest(comp: *Compilation, man: *Cache.Manifes defer arena_allocator.deinit(); const arena = arena_allocator.allocator(); - comptime assert(link_hash_implementation_version == 2); + comptime assert(link_hash_implementation_version == 3); if (comp.bin_file.options.module) |mod| { const main_zig_file = try mod.main_pkg.root_src_directory.join(arena, &[_][]const u8{ @@ -2333,6 +2335,7 @@ fn addNonIncrementalStuffToCacheManifest(comp: *Compilation, man: *Cache.Manifes man.hash.add(comp.bin_file.options.z_notext); man.hash.add(comp.bin_file.options.z_defs); man.hash.add(comp.bin_file.options.z_origin); + man.hash.add(comp.bin_file.options.z_nocopyreloc); man.hash.add(comp.bin_file.options.z_noexecstack); man.hash.add(comp.bin_file.options.z_now); man.hash.add(comp.bin_file.options.z_relro); |
