How set set include path when using <>

On one computer I have #include <RTClib.h> and it works.

On a different computer I had to put in the full path to RTCLib.h because #include <RTClib.h> does not work.

Is there a setting somewhere which says where <*.h> files should be looked for. I could not find one.

TIA

Each library that is added by the user is normally put in a folder of its own in the libraries folder in your sketchbook folder. This is one of the standard places that the compiler will look when you use #include <libraryName.h>. This is also the place that the Library Manager will install libraries

The location of the sketchbook folder can be changed in the IDE Preferences dialogue

My libraries were not inside Sketchbook, but in parallel with it.

When I installed a new library (as a test) it gets put inside the "libraries" parallel with sketchbook.

Please post the full paths to your sketchbook folder and libraries folder and a screenshot showing the sketchbook location in the IDE Preferences dialogue

Will do, but just read that there are two "libraries", un official Arduino, and one for contributions. The one for contributions is, as you said, under "sketchbook".

Libraries are held in several different locations

There are built in libraries in C:\Users<username>\AppData\Local\Arduino15\libraries which are installed with the IDE

Then there are board specific libraries installed with board libraries and these are under C:\Users<username>\AppData\Local\Arduino15\packages, for example, C:\Users<username>\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.1.1\libraries

When you install a library manually, using Install ZIP library or using the library Manager the library is installed in the libraries folder of the sketchbook, or it certainly should be

I needed .

As a test I tried:

#include <ArduinoSTL.h>

and now it all compiles fine, including my use of vector.

A mystery in an enigma, thanks for your pointers.

oops I needed vector in angle brackets

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.