Do not build the firmware target when crosscompiling

pull/55/head
Alan Dragomirecký 2021-07-09 23:06:20 +02:00 committed by DRracer
parent 5018c44489
commit 332c740a8b
1 changed files with 3 additions and 0 deletions

View File

@ -165,6 +165,9 @@ target_compile_options(firmware PRIVATE -Wdouble-promotion)
add_subdirectory(src)
if(NOT CMAKE_CROSSCOMPILING)
# do not build the firmware by default (tests are the focus if not crosscompiling)
set_target_properties(firmware PROPERTIES EXCLUDE_FROM_ALL YES)
enable_testing()
add_subdirectory(tests)
endif()