Skip to content

Commit

Permalink
ldmd2: remove -release flag and get abs-path from sources
Browse files Browse the repository at this point in the history
  • Loading branch information
kassane committed Sep 9, 2024
1 parent 1bbe779 commit 094dd92
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions toolchains/ldmd2.zig
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,11 @@ pub fn BuildStep(b: *std.Build, options: DCompileStep) !*std.Build.Step.InstallD
}),
.ReleaseFast => ldc_exec.addArgs(&.{
"-O3",
"-release",
"-enable-inlining",
"-boundscheck=off",
}),
.ReleaseSmall => ldc_exec.addArgs(&.{
"-Oz",
"-release",
"-enable-inlining",
"-boundscheck=off",
}),
Expand Down Expand Up @@ -179,7 +177,8 @@ pub fn BuildStep(b: *std.Build, options: DCompileStep) !*std.Build.Step.InstallD

// D Source files
for (options.sources) |src| {
ldc_exec.addFileArg(b.path(src));
// get absolute path
ldc_exec.addFileArg(.{ .cwd_relative = src });
}

// linker flags
Expand Down

0 comments on commit 094dd92

Please sign in to comment.