Skip to content

Commit

Permalink
Clarify choice of clang
Browse files Browse the repository at this point in the history
  • Loading branch information
brenhinkeller authored Mar 4, 2024
1 parent 7366189 commit e40370f
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/StaticCompiler.jl
Original file line number Diff line number Diff line change
Expand Up @@ -322,11 +322,8 @@ function generate_executable(funcs::Union{Array,Tuple}, path=tempname(), name=fi
close(f)
if llvm_to_clang # (required on Windows)
# Use clang (llc) to generate an executable from the LLVM IR
if Sys.iswindows()
run(`cmd \c clang -Wno-override-module $wrapper_path $obj_or_ir_path -o $exec_path`)
else
run(`$(clang()) -Wno-override-module $wrapper_path $obj_or_ir_path -o $exec_path`)
end
cclang = Sys.iswindows() ? `cmd \c clang` : clang() # This could be removed if clang_jll reliably works on windows
run(`$cclang -Wno-override-module $wrapper_path $obj_or_ir_path -o $exec_path`)
else
run(`$cc $wrapper_path $cflags $obj_or_ir_path -o $exec_path`)
end
Expand Down

0 comments on commit e40370f

Please sign in to comment.