compiling with windows: i patched fpcupdeluxe to work with the correct tools and adapted the fpc.cfg for the correct type. And build the crosscompiler. this well done (says fpcupdeluxe)
Now i use the following script to make the steps more transparent
@echo on
set IDF_PATH=D:\data\msys32\home\andi\esp\ESP8266_RTOS_SDK
cd D:\data\lazdev\xtensa\projects\helloworld
D:\data\lazdev\xtensa\fpc\bin\i386-win32\ppcrossxtensa -sh -Furtl/units/xtensa-freertos/ -Tfreertos -XPxtensa-lx106-elf- -O- -Wpesp8266 -WP4.0 HelloWorld2.lpr -FlD:\data\msys32\home\andi\esp\xtensa-lx106-elf-libs -FlD:\data\msys32\home\andi\esp\ESP8266_RTOS_SDK\components/esp8266/lib -FED:\data\lazdev\xtensa\projects\helloworld
pause
after this i get a ppas.bat. if i start this i get
Assembling helloworld2
Linking D:\data\lazdev\xtensa\projects\helloworld\HelloWorld2
D:\data\xtensa-lx106-elf\bin\xtensa-lx106-elf-ld.exe: cannot find libc_fnano.a
D:\data\xtensa-lx106-elf\bin\xtensa-lx106-elf-ld.exe: cannot find libstdc++.a
An error occurred while linking D:\data\lazdev\xtensa\projects\helloworld\HelloWorld2
Drücken Sie eine beliebige Taste . . .
it will correct because c_fnano and libstdc++ are not built for this target.
If -WP is larger than 3.3 fpc should load unit esp8266rtos_30400, which only links to libc_nano, not libc_fnano. Your attached build log does not show a unit esp8266_30300 or esp8266_30400 being build, so something is funny with the version of the cross fpc as downloaded and/or build by fpcupdeluxe.
Can you verify that esp8266_30300.pp and esp8266_30400.pp do exist in D:/data/lazdev/xtensa/fpcsrc/rtl/freertos/xtensa and also that these units are referenced in /fpcsrc/rtl/freertos/MakeFile? These changes were implemented in
this commit, but was included before commit 307c284f6a which is your latest fpc revision. So this is a bit puzzling...
Then there remains a problem with locating libstdc++. In the latest bin tools this library should be located in D:\data\xtensa-lx106-elf\xtensa-lx106-elf\lib, together with libc_nano. You either have to copy the libraries in this folder to your overall library folder (D:\data\msys32\home\andi\esp\xtensa-lx106-elf-lib) if these libraries are not already there, or add another -FlD:\data\xtensa-lx106-elf\xtensa-lx106-elf\lib statement to your project's compile command to add this path to fpc's library search list.
Disclaimer: I'm translating from Linux paths to what I assume is equivalent to your Windows folder structures, but the exact paths I mention above may not be correct.