Files
MuditaOS/Target_Linux.cmake
Wiktor S. Ovalle Correa 6b386720e8 [EGD-5289] Fix VFS folder mapping in emulator
Folder filtering prevented us from accessing /sys folder
of VFS image. This fix redirects all /sys references to
the image by default, requiring us to explicitly specify
all paths we want to redirect to Linux fs.
2021-02-17 17:05:32 +01:00

34 lines
1002 B
CMake

set(PROJECT_TARGET "TARGET_Linux" CACHE INTERNAL "")
set(TARGET_SOURCES CACHE INTERNAL "")
set(TARGET_DIR_INCLUDES ${CMAKE_CURRENT_LIST_DIR}/board/linux CACHE INTERNAL "")
set(TARGET_COMPILE_FEATURES CACHE INTERNAL "")
set(TARGET_COMPILE_DEFINITIONS CACHE INTERNAL "")
add_compile_options(-funsigned-char)
set(TARGET_LIBRARIES
rt
pthread
portaudio
CACHE INTERNAL "" )
option (LINUX_ENABLE_SANITIZER "Enable address sanitizer for Linux" ON)
if (LINUX_ENABLE_SANITIZER)
add_compile_options(-fsanitize=address -static-libasan)
add_link_options(-fsanitize=address -static-libasan)
endif (LINUX_ENABLE_SANITIZER)
set(CMAKE_STRIP strip CACHE INTERNAL "")
set(CMAKE_OBJCOPY objcopy CACHE INTERNAL "")
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/sys)
file(CREATE_LINK ${CMAKE_BINARY_DIR}/user ${CMAKE_BINARY_DIR}/sys/user SYMBOLIC)
file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/sys/current)
file(CREATE_LINK ${CMAKE_BINARY_DIR}/assets ${CMAKE_BINARY_DIR}/sys/current/assets SYMBOLIC)