Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When multiple libraries contain files matching an
#include
directive in the program, the Arduino build system must pick one to use for compilation. Multiple factors are used in order to make an intelligent determination of which library is best, as documented here.In order to enhance this determination, the closeness of match between the library.properties
name
value and the filename in the#include
directive is being added as one of those factors. This new factor is referred to as "Library Name Priority". This change has been made in Arduino CLI 0.19.0 (arduino/arduino-cli#1300), and Arduino IDE 2.0.0-beta.12 and newer.Unfortunately, this change can result in platform bundled libraries which had previously been correctly correctly chosen
no longer being given priority over their equivalent standalone libraries, which may be incompatible or not optimized for the platform's boards.
This priority inversion only occurs when all the following conditions are true:
architectures=AmebaD
).architectures=*
).name=WiFi
vsname=AmebaWiFi
for a library with primary header fileWiFi.h
.The fix is to simply give the platform bundled library a perfect "Library Name Priority", as provided by the change in this PR.
Some platform bundled libraries were given a modified name as a workaround to a bug in the Arduino IDE's Library Manager which caused Library Manager to always show the library as updatable under specific circumstances. That bug was fixed in Arduino IDE 1.8.6, ~3 years ago.
For more information or discussion regarding this change, please see arduino/arduino-cli#1292