Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions arch/sim/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ config ARCH_CHIP

choice
prompt "Toolchain Selection"
default SIM_TOOLCHAIN_CLANG if HOST_MACOS
default SIM_TOOLCHAIN_GCC

config SIM_TOOLCHAIN_GCC
Expand Down
9 changes: 7 additions & 2 deletions arch/sim/src/cmake/Toolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#
# ##############################################################################

if(APPLE)
if(APPLE AND CONFIG_SIM_TOOLCHAIN_GCC)
find_program(CMAKE_C_ELF_COMPILER x86_64-elf-gcc)
find_program(CMAKE_CXX_ELF_COMPILER x86_64-elf-g++)
endif()
Expand Down Expand Up @@ -121,7 +121,12 @@ if(CONFIG_STACK_USAGE_WARNING)
endif()

if(CONFIG_COVERAGE_ALL)
add_compile_options(-fprofile-arcs -ftest-coverage -fno-inline)
if(CONFIG_ARCH_TOOLCHAIN_GCC)
add_compile_options(-fprofile-arcs -ftest-coverage -fno-inline)
elseif(CONFIG_ARCH_TOOLCHAIN_CLANG)
add_compile_options(-fprofile-instr-generate -fcoverage-mapping)
add_link_options(-fprofile-instr-generate)
endif()
endif()

if(CONFIG_PROFILE_ALL OR CONFIG_SIM_PROFILE)
Expand Down
1 change: 1 addition & 0 deletions arch/sim/src/sim/posix/sim_hostmisc.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
* Included Files
****************************************************************************/

#include <signal.h>
#include <errno.h>
#include <limits.h>
#include <stdio.h>
Expand Down
Loading