Skip to content

Commit

Permalink
Merge pull request #18 from wilsonk/fix-cpu-model
Browse files Browse the repository at this point in the history
Quick fix for cpu-models improper character replacement with ldc/clang
fix #17
  • Loading branch information
kassane authored May 14, 2024
2 parents 9920862 + 61cc323 commit 12fd2f5
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -501,10 +501,7 @@ pub fn ldcBuildStep(b: *Build, options: DCompileStep) !*RunStep {

// cpu model (e.g. "baseline")
if (options.target.query.isNative()) {
const cpu_model = if (options.target.result.isDarwin())
builtin.cpu.model.llvm_name orelse "generic"
else
builtin.cpu.model.name;
const cpu_model = builtin.cpu.model.llvm_name orelse "generic";
try cmds.append(b.fmt("-mcpu={s}", .{cpu_model}));
}

Expand Down

0 comments on commit 12fd2f5

Please sign in to comment.