meta: add build system

This commit is contained in:
2026-02-05 09:54:46 +00:00
parent 62c5653d5b
commit 9c8fbc72ac
15 changed files with 694 additions and 0 deletions

9
programs/CMakeLists.txt Normal file
View File

@@ -0,0 +1,9 @@
file(GLOB items *)
foreach(item ${items})
if (NOT IS_DIRECTORY ${item})
continue()
endif ()
add_subdirectory(${item})
endforeach (item)

View File

@@ -0,0 +1,9 @@
add_executable(test test.c)
target_link_libraries(test c)
sysroot_add_program(
NAME test
BIN_DIR /usr/bin)
bsp_add_program(
NAME test
BIN_DIR /usr/bin)

6
programs/test/test.c Normal file
View File

@@ -0,0 +1,6 @@
#include <function.h>
int _start(void)
{
return function();
}