I have created a crosscompiler for xtensa and the lx106 (ESP8266). But i am not able to compile a hello world. Exactly the compiling will work, but not the linking.
@echo on
set IDF_PATH=C:\data\esp\ESP8266_RTOS_SDK
cd C:\data\lazdev\xtensa\projects
C:\data\lazdev\xtensa\fpc\bin\i386-win32\ppcrossxtensa -va -Furtl/units/xtensa-freertos/ -Tfreertos -XPxtensa-lx106-elf- -O3 -Wpesp8266 HelloWorld2.lpr -Fl~/esp/xtensa-lx106-elf-libs/ -FlC:\data\esp\ESP8266_RTOS_SDK\components/esp8266/lib -FlC:\data\esp\ESP8266_RTOS_SDK/components/newlib/newlib/lib -Fl~/esp/xtensa-lx106-elf/xtensa-lx106-elf/sysroot/lib/
pause
My SDK is under c:\data\esp, not c.\esp to hold my root clean.
If i try my HelloWorld2.lpr to compile i get the following message.
....
[1.521] Searching file C:\data\lazdev\xtensa\cross\lib\xtensa-freertos\lx106\libstdc++.a... found
[1.523] Searching file C:\data\lazdev\xtensa\cross\lib\xtensa-freertos\lx106\libpthread.a... found
[1.527] Searching file C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-gcc.exe... found
[1.528] Using util C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-gcc.exe
[1.529] Executing "C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-gcc.exe -C -P -x c -E -o /esp8266_out.ld -I / /components/esp8266/ld/esp8266.ld" using comspec "C:\WINDOWS\system32\cmd.exe"
[1.530] Executing "C:\WINDOWS\system32\cmd.exe" with command line " /C C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-gcc.exe -C -P -x c -E -o /esp8266_out.ld -I / /components/esp8266/ld/esp8266.ld"
xtensa-lx106-elf-gcc.exe: error: /components/esp8266/ld/esp8266.ld: No such file or directory
xtensa-lx106-elf-gcc.exe: warning: '-x c' after last input file has no effect
xtensa-lx106-elf-gcc.exe: fatal error: no input files
compilation terminated.
[1.589] HelloWorld2.lpr(13,24) Error: Error while linking
[1.593] Searching file C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-objdump.exe... found
[1.594] Using util C:\data\lazdev\xtensa\cross\bin\xtensa-freertos\bin\xtensa-lx106-elf-objdump.exe
[1.595] Searching file HelloWorld2.o... found
[1.596] Searching file HelloWorld2.o... found
.....
Maybe i have not given all need information to the crosscompiler. But i created my HelloWorld according the wiki
https://wiki.lazarus.freepascal.org/Xtensa point 1.2.4 to test my crosscompiler.
Any hints how to get this working?