mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 13:54:21 +00:00
Add missing clang opts: -install_name and -undefined
This commit is contained in:
parent
11a81e1b29
commit
e9e804edc8
3 changed files with 36 additions and 2 deletions
|
|
@ -3932,7 +3932,14 @@ sepd1("include-pch"),
|
|||
flagpd1("index-header-map"),
|
||||
sepd1("init"),
|
||||
flagpd1("init-only"),
|
||||
sepd1("install_name"),
|
||||
.{
|
||||
.name = "install_name",
|
||||
.syntax = .separate,
|
||||
.zig_equivalent = .install_name,
|
||||
.pd1 = true,
|
||||
.pd2 = false,
|
||||
.psl = false,
|
||||
},
|
||||
flagpd1("keep_private_externs"),
|
||||
sepd1("lazy_framework"),
|
||||
sepd1("lazy_library"),
|
||||
|
|
@ -6326,7 +6333,14 @@ joinpd1("ftabstop="),
|
|||
jspd1("idirafter"),
|
||||
joinpd1("mregparm="),
|
||||
joinpd1("sycl-std="),
|
||||
jspd1("undefined"),
|
||||
.{
|
||||
.name = "undefined",
|
||||
.syntax = .joined_or_separate,
|
||||
.zig_equivalent = .undefined,
|
||||
.pd1 = true,
|
||||
.pd2 = false,
|
||||
.psl = false,
|
||||
},
|
||||
.{
|
||||
.name = "extdirs=",
|
||||
.syntax = .joined,
|
||||
|
|
|
|||
12
src/main.zig
12
src/main.zig
|
|
@ -1697,6 +1697,16 @@ fn buildOutputType(
|
|||
};
|
||||
}
|
||||
},
|
||||
.install_name => {
|
||||
install_name = it.only_arg;
|
||||
},
|
||||
.undefined => {
|
||||
if (mem.eql(u8, "dynamic_lookup", it.only_arg)) {
|
||||
linker_allow_shlib_undefined = true;
|
||||
} else {
|
||||
fatal("unsupported -undefined option '{s}'", .{it.only_arg});
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
// Parse linker args.
|
||||
|
|
@ -4791,6 +4801,8 @@ pub const ClangArgIterator = struct {
|
|||
weak_framework,
|
||||
headerpad_max_install_names,
|
||||
compress_debug_sections,
|
||||
install_name,
|
||||
undefined,
|
||||
};
|
||||
|
||||
const Args = struct {
|
||||
|
|
|
|||
|
|
@ -492,6 +492,14 @@ const known_options = [_]KnownOpt{
|
|||
.name = "compress-debug-sections=",
|
||||
.ident = "compress_debug_sections",
|
||||
},
|
||||
.{
|
||||
.name = "install_name",
|
||||
.ident = "install_name",
|
||||
},
|
||||
.{
|
||||
.name = "undefined",
|
||||
.ident = "undefined",
|
||||
},
|
||||
};
|
||||
|
||||
const blacklisted_options = [_][]const u8{};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue