Starting and testing cmake as a toolchain

This commit is contained in:
2025-12-02 17:22:01 +01:00
parent 2522492835
commit a4acfeceee
4 changed files with 49 additions and 0 deletions

13
kernel/CMakeLists.txt Normal file
View File

@ -0,0 +1,13 @@
project(Kernel LANGUAGES C CXX ASM)
set(SOURCES
main.cpp
boot.s
)
add_executable(kernel.elf ${SOURCES})
target_link_libraries(kernel.elf PRIVATE CoreLib)
set(LINKER_SCRIPT ${CMAKE_CURRENT_SOURCE_DIR}/link.ld)
target_link_options(kernel.elf PRIVATE "-T${LINKER_SCRIPT}")