-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
platformio build on esp32 broken (library.json) #223
Comments
@ivankravets is this doable and how? I have AsyncTCP that replaces ESPAsyncTCP on ESP32, so depending on the platform is which needs to be installed. |
I see 2 quick solutions:
What do you think? |
I like the second solution, but how would the manifests be named so PIO picks them up? |
PIO does not depend strictly on I propose:
Then, we will have 2 records in a registry. If a user specifies Otherwise, we can have 2 different names to avoid "visual conflicts".
|
In the documentation it says you can specify a platform for your dependencies[1]. Wouldn't that do the job, by adding both as a dependency with the relevant platform specified? [1] http://docs.platformio.org/en/latest/librarymanager/config.html?highlight=dependencies#dependencies |
@BlackEdder it does not support specifying the platform, so it would not work. |
@BlackEdder I'm laughing 😆 You are right! Yes, it seems that is will work. PIO will install both libraries, but only compatible will be used firstly. @me-no-dev please merge me-no-dev/ESPAsyncTCP#51 |
@me-no-dev no no, @BlackEdder is right :) |
@ivankravets i am confused now.... what should I do? |
@me-no-dev I can't make PR, you've removed the main Please remove split files and use the one
|
I guess:
should be:
|
@BlackEdder no no, it will be broken manifest. My version is valid. |
done :) should be all good now! Thanks yall! |
@me-no-dev Please sorry that disturb you :( I've just checked all libraries and we have a small issue here. PIO Core works by default in lib_compat_mode = 1, which means, that we collect libraries and checking only for frameworks compatibility. So, the current library will fail by default while a user doesn't set in Sorry, please revert to this commit b7bf1fe but change the description. Currently, it says that library is compatible for esp8266/esp32. Need to specify in these manifests in the description that library is compatible only with X. P.S: I recommend to use "espressif8266" instead of "espressif". |
So, this comment is the final #223 (comment) This is the best solution to keep compatibility with projects which use old PIO Core. Please spit library into 2 manifests. Thanks! |
Done :) split and corrected! |
@me-no-dev Thanks! @BlackEdder Please re-test with http://platformio.org/lib/show/1832/AsyncWebServer |
@me-no-dev and @ivankravets I am now getting errors building for ESP8266, ESPAsyncTCP is no longer being installed (not a dependency of ESPAsyncWebServer). Is this expected and should I be adding an explicit dependency in my platformio.ini?
See https://travis-ci.org/jeremypoulter/ESP8266_WiFi_v2.x/jobs/274570571 for logs, etc |
As pointed out in platformio/platformio-core#1050, I was using a direct reference to the Git repo (I was trying to ensure I had the bleeding edge), this change breaks that as there is now no longer any library.json. That is fine for me specific case but could be a problem if people want to reference forks rather than the official version. |
@jeremypoulter if you decide to manage libraries manually and use GIT versions, you can add
|
@ivankravets ok, cool I guess that will work, thanks |
@ivankravets FYI: I have just figured out why I was using the Git version. My platformio.ini has a specific version for most of the configs and I wanted to have one config that used the latest version for testing. However when using just ESPAsyncWebServer and ESPAsyncWebServer@be12e0c171 both libraries get checked out to .piolibdeps/ESPAsyncWebServer_ID306, when using the the git URL that gets checked out to .piolibdeps/ESPAsyncWebServer so there is no conflict. I will change back to using the Git version and adding the extra dependency, but I presume there is an underlying bug/feature request against the Platform IO core that should come out of this? |
PIO Core does not rely on library folder name. It uses manifest inside it.
Could you explain in details? P.S: If you need to use custom libraries/versions per a few projects, you can use extra library storage. |
Checking in here. This doesn't work for me (platformio/platformio-core#1098), even when using the git version of this repo. |
@me-no-dev it's almost working. Could you add a
to the dependencies? Otherwise it won't work with lib_compat_mode=2 and stage platform. |
Or rather have
as dependencies. |
me-no-dev/AsyncTCP#3 and #239 should help with the staging version. |
I think we should move away from For example,
|
Because the library.json file includes a dependency on ESPAsyncTCP.h the library fails to build on esp32 hardware. This dependency should probably be hardware specific.
The text was updated successfully, but these errors were encountered: