Commit b0bfde917b

Jeremy Volkman <jeremy@cedarai.com>
2022-12-27 17:15:09
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.
1 parent a70cbe7
Changed files (1)
src/main.zig
@@ -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});
                         }