File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -221,12 +221,18 @@ function(_zig_generate_shim tool_name subcommand inject_flags use_ccache)
221221 message (STATUS "Zig Toolchain: Compiling native wrapper for '${tool_name} '..." )
222222
223223 if (CMAKE_HOST_APPLE )
224- set (_shim_strip_flag "" )
224+ set (_shim_compile_cmd
225+ "${_zig_compiler_exe} " cc -O2 -std=c11 -march=native -target native-macos
226+ "${_shim_src} " -o "${_shim_exe} "
227+ )
225228 else ()
226- set (_shim_strip_flag "-s" )
229+ set (_shim_compile_cmd
230+ "${_zig_compiler_exe} " cc -O2 -std=c11 -march=native -s
231+ "${_shim_src} " -o "${_shim_exe} "
232+ )
227233 endif ()
228234 execute_process (
229- COMMAND " ${_zig_compiler_exe} " cc -O2 ${_shim_strip_flag} " ${_shim_src} " -o " ${_shim_exe} "
235+ COMMAND ${_shim_compile_cmd}
230236 RESULT_VARIABLE _compile_result
231237 ERROR_VARIABLE _compile_stderr
232238 OUTPUT_QUIET
You can’t perform that action at this time.
0 commit comments