Use optimal bundled library name by per1234 · Pull Request #8088 · esp8266/Arduino (original) (raw)
There is no urgent requirement that I'm aware of to bring those library names into compliance with the specification. My investigation indicated that they are not affected by arduino/arduino-cli#1292.
In the case of the Servo library, the standalone version provides an explicit list of compatible architectures:
https://github.com/arduino-libraries/Servo/blob/master/library.properties#L9
architectures=avr,megaavr,sam,samd,nrf52,stm32f4,mbed,mbed_nano,mbed_portenta,mbed_rp2040
Since esp8266
is not on that list, and the platform bundled Servo library does list compatibility:
https://github.com/esp8266/Arduino/blob/master/libraries/Servo/library.properties#L9
the platform bundled version wins on the first library priority factor:
https://arduino.github.io/arduino-cli/dev/sketch-build-process/#dependency-resolution
A library that is architecture compatible wins against a library that is not architecture compatible (see Architecture Matching)
So even with the current library name/#include
filename mismatch, the correct Servo library will still always be chosen.
However, there is no guarantee of continued support for non-compliant bundled library names. So I do think it is safest to bring them into compliance with an eye on the future.
If you're still concerned about people using >3 year outdated versions of the Arduino IDE being affected by arduino/Arduino#4189, you can change the library names to something that is still unique from the Library Manager library names, but in a specification compliant manner. Something like:
That works just as well for the arduino/Arduino#4189 workaround. The parentheses were in no way required, but only a dumb idea I had at the time.
In the case of LittleFS, it is not even susceptible to arduino/Arduino#4189 because there is no library in the Library Manager index with that name.