diff options
Diffstat (limited to 'host/CMakeLists.txt')
-rw-r--r-- | host/CMakeLists.txt | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/host/CMakeLists.txt b/host/CMakeLists.txt new file mode 100644 index 0000000..d3bfe17 --- /dev/null +++ b/host/CMakeLists.txt @@ -0,0 +1,28 @@ +cmake_minimum_required(VERSION 3.2) + +project(host C CXX ASM) + +add_executable(host1.elf host1.cpp + ../tinyprintf/tinyprintf.h ../tinyprintf/tinyprintf.c + ) + +target_include_directories(host1.elf PUBLIC + ../tinyprintf + ../include) +target_compile_definitions(host1.elf PUBLIC TINYPRINTF_DEFINE_TFP_SPRINTF=0 TINYPRINTF_OVERRIDE_LIBC=0) + +add_executable(elf3 elf3.cpp) +target_link_libraries(elf3 elf) + +add_executable(elf4 elf4.cpp) +target_link_libraries(elf4 elf bsd) + +add_executable(elfinfo elfinfo.cpp) +target_compile_options(elfinfo PUBLIC "--std=c++14") +target_link_libraries(elfinfo elf) + +INSTALL(TARGETS elfinfo + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) |