2020-12-07 01:40:10 +01:00
|
|
|
# Check the OS_FSFW variable
|
|
|
|
if(${OS_FSFW} STREQUAL "freertos")
|
2021-03-30 00:37:10 +02:00
|
|
|
add_subdirectory(FreeRTOS)
|
2020-12-07 01:40:10 +01:00
|
|
|
elseif(${OS_FSFW} STREQUAL "rtems")
|
2021-03-30 00:37:10 +02:00
|
|
|
add_subdirectory(rtems)
|
2020-12-07 01:40:10 +01:00
|
|
|
elseif(${OS_FSFW} STREQUAL "linux")
|
2021-03-30 00:37:10 +02:00
|
|
|
add_subdirectory(linux)
|
2020-12-07 01:40:10 +01:00
|
|
|
elseif(${OS_FSFW} STREQUAL "host")
|
2021-03-30 00:37:10 +02:00
|
|
|
add_subdirectory(host)
|
|
|
|
if (WIN32)
|
|
|
|
add_subdirectory(windows)
|
|
|
|
elseif(UNIX)
|
|
|
|
# We still need to pull in some Linux specific sources
|
|
|
|
target_sources(${LIB_FSFW_NAME} PUBLIC
|
|
|
|
linux/tcpipHelpers.cpp
|
|
|
|
)
|
|
|
|
endif ()
|
2020-12-07 01:40:10 +01:00
|
|
|
|
|
|
|
else()
|
|
|
|
|
2021-03-30 00:37:10 +02:00
|
|
|
message(WARNING "The OS_FSFW variable was not set. Assuming host OS..")
|
|
|
|
# Not set. Assumuing this is a host build, try to determine host OS
|
|
|
|
if (WIN32)
|
|
|
|
add_subdirectory(host)
|
|
|
|
add_subdirectory(windows)
|
|
|
|
elseif (UNIX)
|
|
|
|
add_subdirectory(linux)
|
|
|
|
else ()
|
|
|
|
# MacOS or other OSes have not been tested yet / are not supported.
|
|
|
|
message(FATAL_ERROR "The host OS could not be determined! Aborting.")
|
|
|
|
endif()
|
2020-12-07 01:40:10 +01:00
|
|
|
|
2021-03-12 18:06:24 +01:00
|
|
|
endif()
|
|
|
|
|
|
|
|
add_subdirectory(common)
|