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

User avatar
By pvdw
#83489 I try to use the sketch simple.ino of the configmanager lib of Nicholas Wiersma and if I compile I get a error. I mailed the author and his reply is =>
" That there is a compiling problem with the general esp8266 libs. It is more than likely something wrong with your setup, like you are compiling against the wrong target or something like that, so it cannot figure out the correct UDP code to use, that would be my guess anyway. I would suggest you look to the esp8266 Arduino forums for help here."
So now I putting a post to have a look if there is anybody that knows how to solve that problem. Or what I have to do to change some general esp8266 libs.

***********************************************************************************************************************************

"C:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\tools\\xtensa-lx106-elf-gcc\\2.5.0-3-20ed2b9/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0/tools/sdk/include" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0/tools/sdk/lwip2/include" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0/tools/sdk/libc/xtensa-lx106-elf/include" "-IC:\\Users\\peter\\AppData\\Local\\Temp\\arduino_build_784396/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=c++11 -MMD -ffunction-sections -fdata-sections -fno-exceptions -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10809 -DARDUINO_ESP8266_NODEMCU -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD=\"ESP8266_NODEMCU\"" -DFLASHMODE_DIO -DESP8266 "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\cores\\esp8266" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\variants\\nodemcu" "-IC:\\Users\\peter\\Documents\\Arduino\\libraries\\ConfigManager\\src" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\libraries\\DNSServer\\src" "-IC:\\Program Files (x86)\\Arduino\\libraries\\WiFi\\src" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\libraries\\EEPROM" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\libraries\\ESP8266WiFi\\src" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\libraries\\ESP8266WebServer\\src" "-IC:\\Users\\peter\\Documents\\Arduino\\libraries\\ArduinoJson\\src" "-IC:\\Users\\peter\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.5.0\\libraries\\SPI" "C:\\Users\\peter\\AppData\\Local\\Temp\\arduino_build_784396\\sketch\\simple.ino.cpp" -o "C:\\Users\\peter\\AppData\\Local\\Temp\\arduino_build_784396\\sketch\\simple.ino.cpp.o"
In file included from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\src/ConfigManager.h:4:0,

from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\examples\simple\simple.ino:1:

C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\DNSServer\src/DNSServer.h:67:13: error: cannot declare field 'DNSServer::_udp' to be of abstract type 'WiFiUDP'

WiFiUDP _udp;

^

In file included from C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\DNSServer\src/DNSServer.h:3:0,

from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\src/ConfigManager.h:4,

from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\examples\simple\simple.ino:1:

C:\Program Files (x86)\Arduino\libraries\WiFi\src/WiFiUdp.h:27:7: note: because the following virtual functions are pure within 'WiFiUDP':

class WiFiUDP : public UDP {

^

In file included from C:\Program Files (x86)\Arduino\libraries\WiFi\src/WiFiUdp.h:23:0,

from C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\DNSServer\src/DNSServer.h:3,

from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\src/ConfigManager.h:4,

from C:\Users\peter\Documents\Arduino\libraries\ConfigManager\examples\simple\simple.ino:1:

C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\cores\esp8266/Udp.h:82:27: note: virtual IPAddress UDP::remoteIP() const

virtual IPAddress remoteIP() const =0;

^

C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\cores\esp8266/Udp.h:84:26: note: virtual uint16_t UDP::remotePort() const

virtual uint16_t remotePort() const =0;

^

Meerdere bibliotheken gevonden voor "WiFiUdp.h"
Gebruikt: C:\Program Files (x86)\Arduino\libraries\WiFi
Niet gebruikt: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\ESP8266WiFi
Bibliotheek ConfigManager op versie 1.4 in map: C:\Users\peter\Documents\Arduino\libraries\ConfigManager wordt gebruikt
Bibliotheek DNSServer op versie 1.1.1 in map: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\DNSServer wordt gebruikt
Bibliotheek WiFi op versie 1.2.7 in map: C:\Program Files (x86)\Arduino\libraries\WiFi wordt gebruikt
Bibliotheek EEPROM op versie 1.0 in map: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\EEPROM wordt gebruikt
Bibliotheek ESP8266WiFi op versie 1.0 in map: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\ESP8266WiFi wordt gebruikt
Bibliotheek ESP8266WebServer op versie 1.0 in map: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\ESP8266WebServer wordt gebruikt
Bibliotheek ArduinoJson op versie 5.13.2 in map: C:\Users\peter\Documents\Arduino\libraries\ArduinoJson wordt gebruikt
Bibliotheek SPI op versie 1.0 in map: C:\Users\peter\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.0\libraries\SPI wordt gebruikt
exit status 1

************************************************************************************************************************
User avatar
By pvdw
#83494 I tested the library with arduino IDE 1.8.3 and the compilation was ok. When I compile it with arduino IDE 1.8.9 I get the error : error: cannot declare field 'DNSServer::_udp' to be of abstract type 'WiFiUDP'

WiFiUDP _udp;

^
Please advice what to do. Many thanks