mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 05:44:20 +00:00
stage3 macos: enable -headerpad_max_install_names
This pads the install names area in final (stage3) zig executable on macos. The executable size grows by 4096 bytes, or roughly 0.002% . closes #13388
This commit is contained in:
parent
be6a81d3a7
commit
7d538d6e53
1 changed files with 4 additions and 0 deletions
|
|
@ -569,6 +569,10 @@ fn addCmakeCfgOptionsToExe(
|
|||
exe: *std.build.LibExeObjStep,
|
||||
use_zig_libcxx: bool,
|
||||
) !void {
|
||||
if (exe.target.isDarwin()) {
|
||||
// useful for package maintainers
|
||||
exe.headerpad_max_install_names = true;
|
||||
}
|
||||
exe.addObjectFile(fs.path.join(b.allocator, &[_][]const u8{
|
||||
cfg.cmake_binary_dir,
|
||||
"zigcpp",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue