Implemented runtime files and tests

This commit is contained in:
Max Wash
2020-03-31 12:55:52 +01:00
parent 4cc8e52052
commit 28256512c9
8 changed files with 59 additions and 13 deletions

8
tests/CMakeLists.txt Normal file
View File

@@ -0,0 +1,8 @@
file(GLOB test_sources ${CMAKE_CURRENT_SOURCE_DIR}/*.c)
foreach (test ${test_sources})
get_filename_component(test_name ${test} NAME_WE)
add_executable(${test_name} ${test} $<TARGET_OBJECTS:crt>)
target_compile_options(${test_name} PRIVATE -ffreestanding -nostdlib -nostdinc)
target_link_libraries(${test_name} c)
endforeach (test)