Commit a0cd4c0f32

Andrew Kelley <andrew@ziglang.org>
2022-02-02 22:54:14
CLI: link_libcpp implies link_libc
Improves a warning message for some cases of using `zig run -lc++`.
1 parent d107ef8
Changed files (1)
src/main.zig
@@ -2011,6 +2011,10 @@ fn buildOutputType(
             i += 1;
         }
     }
+    // libc++ depends on libc
+    if (link_libcpp) {
+        link_libc = true;
+    }
 
     if (use_lld) |opt| {
         if (opt and cross_target.isDarwin()) {