Compare commits

...

4 Commits

Author SHA1 Message Date
alex 47e15e1eb9 actually adds linker map to test cases 2026-06-14 14:01:30 +02:00
alex b232f133ac updates netxduo remote 2026-06-09 18:10:29 +02:00
alex 383cdd4887 adds linker group to setup_target 2026-06-05 17:30:20 +02:00
alex cdac2a9f0d allows moonlight to find libc functionality in case nostdlib is set 2026-06-05 12:52:23 +02:00
4 changed files with 6 additions and 3 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
url = https://github.com/Minres/threadx.git url = https://github.com/Minres/threadx.git
[submodule "third-party/netxduo"] [submodule "third-party/netxduo"]
path = third-party/netxduo path = third-party/netxduo
url = https://github.com/eclipse-threadx/netxduo.git url = https://github.com/Minres/netxduo.git
[submodule "third-party/picolibc"] [submodule "third-party/picolibc"]
path = third-party/picolibc path = third-party/picolibc
url = https://github.com/picolibc/picolibc.git url = https://github.com/picolibc/picolibc.git
+3 -2
View File
@@ -14,6 +14,7 @@ add_subdirectory(third-party/picolibc)
#add_subdirectory(picolibc/semihost) #add_subdirectory(picolibc/semihost)
target_sources(c PRIVATE ${CMAKE_CURRENT_LIST_DIR}/port/picolibc/port.c) target_sources(c PRIVATE ${CMAKE_CURRENT_LIST_DIR}/port/picolibc/port.c)
target_link_libraries(c PUBLIC moonlight gcc) target_link_libraries(c PUBLIC moonlight gcc)
target_link_libraries(moonlight PRIVATE c)
############################################################################### ###############################################################################
# Adds threadx # Adds threadx
set(THREADX_CUSTOM_PORT ${CMAKE_CURRENT_LIST_DIR}/port/threadx) set(THREADX_CUSTOM_PORT ${CMAKE_CURRENT_LIST_DIR}/port/threadx)
@@ -40,7 +41,7 @@ endif()
target_include_directories(netxduo PRIVATE ${CMAKE_CURRENT_LIST_DIR}/port/moonlight) target_include_directories(netxduo PRIVATE ${CMAKE_CURRENT_LIST_DIR}/port/moonlight)
target_link_libraries(netxduo PUBLIC threadx c) target_link_libraries(netxduo PUBLIC threadx c)
############################################################################### ###############################################################################
project(threadx_demo C ASM) project(threadx_demo C CXX ASM)
set(TARGET_MEM "ram" CACHE STRING "memory map to use") set(TARGET_MEM "ram" CACHE STRING "memory map to use")
option(NX_DEBUG "compile netxduo debug output in" OFF) option(NX_DEBUG "compile netxduo debug output in" OFF)
option(NX_DEBUG_PACKET "compile netxduo debug output for ethernet packets in" OFF) option(NX_DEBUG_PACKET "compile netxduo debug output for ethernet packets in" OFF)
@@ -65,7 +66,7 @@ function(setup_target TARGET)
endif() endif()
if(ST_LIBRARIES) if(ST_LIBRARIES)
target_link_libraries(${TARGET} PRIVATE ${ST_LIBRARIES}) target_link_libraries(${TARGET} PRIVATE -Wl,--start-group ${ST_LIBRARIES} -Wl,--end-group)
endif() endif()
if(ST_TARGET_MEM) if(ST_TARGET_MEM)
+1
View File
@@ -81,6 +81,7 @@ function(setup_target TARGET)
endif() endif()
target_link_options(${TARGET} PRIVATE target_link_options(${TARGET} PRIVATE
-T ${TARGET_MEM}.lds
-Wl,-Map=${CMAKE_BINARY_DIR}/${TARGET}.map) -Wl,-Map=${CMAKE_BINARY_DIR}/${TARGET}.map)
add_custom_command(TARGET ${TARGET} POST_BUILD add_custom_command(TARGET ${TARGET} POST_BUILD
+1
View File
@@ -83,6 +83,7 @@ function(setup_target TARGET)
endif() endif()
target_link_options(${TARGET} PRIVATE target_link_options(${TARGET} PRIVATE
-T ${TARGET_MEM}.lds
-Wl,-Map=${CMAKE_BINARY_DIR}/${TARGET}.map) -Wl,-Map=${CMAKE_BINARY_DIR}/${TARGET}.map)
add_custom_command(TARGET ${TARGET} POST_BUILD add_custom_command(TARGET ${TARGET} POST_BUILD