File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -48,19 +48,22 @@ macro(project_elf project_name)
4848 endif ()
4949
5050 # Link input list of libraries to ELF
51+ list (APPEND ELF_COMPONENTS "main" )
5152 if (ELF_COMPONENTS)
5253 foreach (c "${ELF_COMPONENTS} " )
53- set (elf_libs "${elf_libs} " "esp-idf/${c} /lib${c} .a" )
54+ list (APPEND elf_libs "esp-idf/${c} /lib${c} .a" )
55+ list (APPEND elf_dependeces "idf::${c} " )
5456 endforeach ()
5557 endif ()
56-
57- set (elf_libs ${elf_libs} "${ELF_LIBS} " "esp-idf/main/libmain.a" )
58+ if (ELF_LIBS)
59+ list (APPEND elf_libs "${ELF_LIBS} " )
60+ endif ()
5861 spaces2list(elf_libs)
5962
6063 add_custom_command (OUTPUT elf_app
6164 COMMAND ${CMAKE_C_COMPILER} ${cflags} ${elf_libs} -o ${elf_app}
6265 COMMAND ${CMAKE_STRIP} ${strip_flags} ${elf_app}
63- DEPENDS ${elf_libs }
66+ DEPENDS ${elf_dependeces }
6467 COMMENT "Build ELF: ${elf_app} "
6568 )
6669 add_custom_target (elf ALL DEPENDS elf_app)
Original file line number Diff line number Diff line change 11[sections:elf_loader_got_plt]
22entries:
33 .got.plt
4+ .got
45
56[scheme:elf_loader_default]
67entries:
You can’t perform that action at this time.
0 commit comments