mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-09-05 21:51:56 +00:00
A new arch (posix) which relies on pthreads to emulate the context switching A new soc for it (inf_clock) which emulates a CPU running at an infinely high clock (so when the CPU is awaken it runs till completion in 0 time) A new board, which provides a trivial system tick timer and irq generation. Origin: Original Fixes #1891 Signed-off-by: Alberto Escolar Piedras <alpi@oticon.com> Signed-off-by: Anas Nashif <anas.nashif@intel.com>
32 lines
1.2 KiB
CMake
32 lines
1.2 KiB
CMake
# Configures CMake for using GCC, this script is re-used by several
|
|
# GCC-based toolchains
|
|
|
|
set(CMAKE_C_COMPILER gcc CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_OBJCOPY objcopy CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_OBJDUMP objdump CACHE INTERNAL " " FORCE)
|
|
#set(CMAKE_LINKER ld CACHE INTERNAL " " FORCE) # Not in use yet
|
|
set(CMAKE_AR ar CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_RANLILB ranlib CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_READELF readelf CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_GDB gdb CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_C_FLAGS -m32 CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_CXX_FLAGS -m32 CACHE INTERNAL " " FORCE)
|
|
set(CMAKE_SHARED_LINKER_FLAGS -m32 CACHE INTERNAL " " FORCE)
|
|
|
|
#assert_exists(CMAKE_READELF)
|
|
|
|
if(CONFIG_CPLUSPLUS)
|
|
set(cplusplus_compiler g++)
|
|
else()
|
|
if(EXISTS g++)
|
|
set(cplusplus_compiler g++)
|
|
else()
|
|
# When the toolchain doesn't support C++, and we aren't building
|
|
# with C++ support just set it to something so CMake doesn't
|
|
# crash, it won't actually be called
|
|
set(cplusplus_compiler ${CMAKE_C_COMPILER})
|
|
endif()
|
|
endif()
|
|
set(CMAKE_CXX_COMPILER ${cplusplus_compiler} CACHE INTERNAL " " FORCE)
|
|
|