I am using the arduino-cli on a Raspberry Pi.
I have installed the esp8266 on in the board manager.
Using command: arduino-cli compile -b esp8266:esp8266:generic wifiman.ino -v
it runs through the notifications and then has this to say:
.../WiFiManager.h:23:10: fatal error: vector: No such file or directory
23 | #include
compilation terminated.
I can't find a vector library to install, Google hasn't shown me solutions. Help please!
vector is usually part of the Standard Template Library, which may not be shipped with the esp8266 core.
Maybe you could try to install the following library (I do not know whether it is fully compatible with the standard implementation) and include it before you include WiFiManager.h.
Otherwise, here are some instructions on how to install an implementation of the STL.
I had more of a think on this one. Your example sketch referenced directly and worked fine. My sketch that is giving me trouble #include <WiFiManager.h> which in turn has #include .
Then I created a test.ino in the same folder as my original sketch
#include <vector>
void setup (){}
void loop (){}
No go, fatal error: vector: No such file or directory.
My original sketch was in ~/wifiman/wifiman.ino. I created a new folder in ~/Arduino >> ~/Arduino/sketchs/wifiman and moved everthing over there. It works fine now.
I don't know why that makes a difference but someone who is smarter than I may find that information useful to diagnose the problem.
If you don't consider it a secret, what is the true path ~ aliases (e.g., the output of echo ~)?
The reason I ask is because there have been some problems with certain characters in paths breaking the Arduino build system's library discovery. Even though it seems less likely since the working sketch path is also under ~, it is possible that the problematic folder name being the direct parent of the sketch is a required condition of the bug.