Discuss here different C compiler set ups, and compiling executables for the ESP8266

User avatar
By markbee
#7012 Yes, would appreciate a simple application to test. Still getting errors with the linker like:

Code: Select allC:\ESP8266\Apps\xPL-ESP8266>make
LD build\app.out
C:\ESP8266\xtensa-lx106-elf\bin\xtensa-lx106-elf-gcc -LC:\ESP8266\esp_iot_rtos_s
dk-master\lib -TC:\ESP8266\esp_iot_rtos_sdk-master\ld\eagle.app.v6.ld -nostdlib
-Wl,--no-check-sections -u call_user_start -Wl,-static -Wl,--start-group -lgcc -
lhal -lphy -lpp -lnet80211 -lwpa -lmain -lfreertos -llwip -ludhcp build\app_app.
a -Wl,--end-group -o build\app.out
C:\ESP8266\esp_iot_rtos_sdk-master\lib\libmain.a(app_main.o): In function `wdt_i
nit':
(.irom0.text+0x380): undefined reference to `user_init'
C:\ESP8266\esp_iot_rtos_sdk-master\lib\libmain.a(app_main.o): In function `wdt_i
nit':
(.irom0.text+0x3db): undefined reference to `user_init'
collect2.exe: error: ld returned 1 exit status
make: *** [build\app.out] Error 1


I'm still not sure about the dashes in the Makefile. Are they supposed to be the way they are in the git resource?

peteben wrote:Anything I need to fix?

If you don't want to install a full xPL setup for testing, I have a small application that will allow you to test.

Let me know if you need it.

Pete
User avatar
By peteben
#7017 Strange. 'user_main' is the program's entry point, in user_main.c. It should have compiled into the library app_app.a, in the build directory. Mine is 198k.

Also, which dashes/slashes are talking about? Post your Makefile so I can check.

Pete