Add support for -undefined error

`-undefined dynamic_lookup` was added in #13991. `-undefined error` is the
opposite, and can be used to revert an `-undefined dynamic_lookup` flag
specified previously on the command line.
This commit is contained in:
Jeremy Volkman 2022-12-27 08:15:09 -08:00
parent a70cbe779a
commit b0bfde917b

View File

@ -1703,6 +1703,8 @@ fn buildOutputType(
.undefined => {
if (mem.eql(u8, "dynamic_lookup", it.only_arg)) {
linker_allow_shlib_undefined = true;
} else if (mem.eql(u8, "error", it.only_arg)) {
linker_allow_shlib_undefined = false;
} else {
fatal("unsupported -undefined option '{s}'", .{it.only_arg});
}