Hi

I still have problems by compiling a NuttX project using the exported libraries and the Makefile usually used to compile other targets under pysimCoder.

I've recompiled the .ld files as ld.tmp and the I changed the name to .ld again in order to find them in my Makefile... I don't know if it is correct...

%.ld.tmp: %.ld
    $(CPP) -isystem $(NUTTX_EXPORT)/include -D__NuttX__ -DNDEBUG -D__KERNEL__ \
    -I$(NUTTX_EXPORT)/arch/chip \
    -I $(NUTTX_EXPORT)/arch/os/sched -o $@ $<

mv <name>.ld.tmp <name>.ld

After this I launch my makefile again and I obtain:

 xtensa-esp32-elf-ld -nostdlib --gc-sections --cref -Map=/home/bucher/sviluppo/NUTTX/nuttx/nuttx.map -L /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/libs --entry=__start  -o ../test.elf \   -r -e main -T /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/scripts/gnu-elf.ld \
  -Map test.elf.map \
  nuttx_main.o test.o /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/lib/libpyblk.a --start-group /home/bucher/sviluppo/GITHUB/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/11.2.0/libgcc.a --end-group
### Created ELF loadable file: test.elf

the elf file seems to be correctly generated, but after this I have a lot of errors:

xtensa-esp32-elf-ld: warning: cannot find entry symbol __start; not setting start address

and a lot of undefined' symbols like for example:

xtensa-esp32-elf-ld -nostdlib --gc-sections --cref -Map=/home/bucher/sviluppo/NUTTX/nuttx/nuttx.map -L /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/libs --entry=__start  -T /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/scripts/esp32_rom.ld -T /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/scripts/flat_memory.ld -T /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/scripts/legacy_sections.ld \
  -o ../test  \
  nuttx_main.o test.o  nuttx_main-builtintab.o /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/lib/libpyblk.a --start-group -lsched -ldrivers -lboards -lc -lmm -larch -lm -lxx -lapps -lnet -lfs -lbinfmt -lwireless -lboard -lboard /home/bucher/sviluppo/GITHUB/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/11.2.0/libgcc.a --end-group xtensa-esp32-elf-ld: warning: cannot find entry symbol __start; not setting start address

xtensa-esp32-elf-ld: /home/bucher/CACSD/pysimCoder/CodeGen/nuttx/nuttx-export/libs/libarch.a(esp32_wifi_adapter.o):(.literal.esp_evt_work_cb+0x14): undefined reference to `esp_wifi_set_ps'
...

Any idea?  Does exist a a makefile for ESP32 that uses the "nuttx-export" files?

Thanks in advance

Roberto




Reply via email to