Library, include order

Hi folks.

[env:d1_mini]
platform = espressif8266
board = d1_mini
framework = arduino
lib_deps = 
    blynkkk/Blynk@^1.0.1
    gyverlibs/GyverPortal

This platformio.ini config causes an error

.pio\libdeps\d1_mini\Blynk\src/BlynkSimpleEsp8266.h:21:2: error: #error Please update your ESP8266 Arduino Core

Reason of this is that
#include <version.h>
in BlynkSimpleEsp8266.h:21:2 from Blynk library include ‘version.h’ from GyverPortal library. Not from framework-arduinoespressif8266. So ESP_SDK_VERSION_NUMBER was undefined and cause this error. How to resolve this? Thanks in advance.

Well are you using the latest version? Either update via PIO Home → Platforms → Espressif 8266 → Update or open a CLIpio pkg update -g -p espressif8266.

@maxgerhardt

Yes. I use last version. ESP_SDK_VERSION_NUMBER defined as 0x020200.
Problem is that #include <version.h> in BlynkSimpleEsp8266.h include #include <version.h> not from framework-arduinoespressif8266 but from other lib (GyverPortal). Of course I can remove

#if ESP_SDK_VERSION_NUMBER < 0x020200
#error Please update your ESP8266 Arduino Core
#endif

from BlynkSimpleEsp8266.h. In this case all build and work fine. But share code that not work from box to other users is a not good idea.