-
Notifications
You must be signed in to change notification settings - Fork 447
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
Not detecting library directory #497
Comments
Use See Blink example and issue #320 |
Ok. In that case, the docs should probably be updated. This explicitly says Is it possible to include relative directories? I have a library in the same directory as my makefile, and to simplify installation and maintainability, I'd prefer to avoid having to copy it into my sketchbook. However, if I use the setting:
it still complains that it can't find the library. |
have a look through the other issues, there's a few regarding libraries in the sketch directory, don't think its possible, but paths like "." are never going to work in a Makefile |
Is appending multiple paths to
it causes make to not find any libraries. Whereas each path by itself at least allows make to find the libraries at those paths: e.g. This partially works (it finds libraries in my sketchbook, but not in the cwd):
and this partially works (it finds libraries in my cwd, but not in my sketchbook):
|
fixed the tilde documentation issue in PR #500 now merged |
My end goal is to allow inclusion of a local Is there any way to currently accomplish this with Arduino-Makefile? |
@chrisspen - I did something similar with the bare arduino project |
@chrisspen and actually you'll need to take a look at our fork of the arduino-makefile https://github.com/weareleka/Arduino-Makefile |
Is there no solution for this? My code looks like:
My makefile looks like:
But when I run
Why isn't it finding secondary includes in either the ARDUINO_SKETCHBOOK or USER_LIB_PATH? I noticed that, for some odd reason, the g++ command outputted doesn't actually include either of these paths as a Am I not configuring arduino-mk correctly, or is this a bug? This seems like a very simple feature that isn't working. |
The problem seems to be that arduino-mk completely ignores ARDUINO_SKETCHBOOK, and it doesn't directly include USER_LIB_PATH but instead uses that as a base folder to include the sub-folders that match items in ARDUINO_LIBS. So it's not finding However, why isn't ARDUINO_SKETCHBOOK being used? If I comment out my custom USER_LIB_PATH, then I get the completely nonsensical error message:
Yes...it'd be found if it checked ARDUINO_SKETCHBOOK. Why isn't that being used as a search path? |
@ladislas i thought you wrote some sort of library autodetection script but your fork seems identical to upstream now? @chrisspen |
@sej7278 I'm following upstream (you) closely and then reapplying my changes each time. you have to checkout the auto-lib branch: https://github.com/weareleka/Arduino-Makefile/tree/auto-lib here are the differences |
I have a number of extra libraries installed in
/home/$USER/Arduino/libraries
, which I can compile with from inside the Arduino IDE. However, if I try to compile with the makefile, I get the error:Please add support for custom library paths.
I tried setting USER_LIB_PATH, but this doesn't appear to support
$USER
or~
, and my application doesn't allow hard-coding the username in the path, since it's not a static value.The text was updated successfully, but these errors were encountered: