diff --git a/lib/std/Build/Step/Compile.zig b/lib/std/Build/Step/Compile.zig index 92db0ca0a0..941f01dd75 100644 --- a/lib/std/Build/Step/Compile.zig +++ b/lib/std/Build/Step/Compile.zig @@ -1786,7 +1786,8 @@ fn make(step: *Step, options: Step.MakeOptions) !void { } if (compile.kind == .lib and compile.linkage != null and compile.linkage.? == .dynamic and - compile.version != null and std.Build.wantSharedLibSymLinks(compile.rootModuleTarget())) + compile.version != null and compile.generated_bin != null and + std.Build.wantSharedLibSymLinks(compile.rootModuleTarget())) { try doAtomicSymLinks( step,