From 378972285342f52bb71822d87ba261b76b4a42ed Mon Sep 17 00:00:00 2001 From: Alexey Gavrilov Date: Sat, 28 Mar 2026 14:55:53 +0700 Subject: Cmake build type at the generation stage Fix in *nasm* files - set architecture bitness. Move compiler flags from *toolchain* file to *requirements target* considering cmake files. This solution allows available of multi-configurations generators to pass compiler options without affecting on single-configuration generators. TODO - Debug information - Image creation - Build under window platform (optional) Signed-off-by: Alexey Gavrilov --- libgcc/x86/CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'libgcc/x86/CMakeLists.txt') diff --git a/libgcc/x86/CMakeLists.txt b/libgcc/x86/CMakeLists.txt index 2a1bec9..8b2eb67 100644 --- a/libgcc/x86/CMakeLists.txt +++ b/libgcc/x86/CMakeLists.txt @@ -4,6 +4,9 @@ target_sources(CRTIBUNDLE PRIVATE ${CMAKE_CURRENT_LIST_DIR}/crti.nasm $ ) +target_link_libraries(CRTIBUNDLE PUBLIC + ASM_NASM_COMPILER_REQUIREMENTS +) target_link_libraries(CRTI INTERFACE CRTIBUNDLE) add_library(CRTN INTERFACE) @@ -12,4 +15,7 @@ target_sources(CRTNBUNDLE PRIVATE ${CMAKE_CURRENT_LIST_DIR}/crtn.nasm $ ) +target_link_libraries(CRTNBUNDLE PUBLIC + ASM_NASM_COMPILER_REQUIREMENTS +) target_link_libraries(CRTN INTERFACE CRTNBUNDLE) -- cgit v1.2.3