Open gnthibault opened 5 years ago
Edit: Actually, fix for this issue was mentionned by @MrPointer in https://github.com/arduino-cmake/Arduino-CMake-NG/issues/55
It is a matter of order
But now I get:
/home/user/Documents/tests/Arduino/arduinocmake/src/Firmata.cpp:27:18: fatal error: Wire.h: No such file or directory
Although Wire.h is in
/path/arduino-1.8.8/hardware/arduino/avr/libraries/Wire/src/Wire.h
So it now looks clear that there is a problem with the find_arduino_library when it comes to something that is not in the libraries subdirectory of the arduino sdk, like for Wire:
find_arduino_library(Wire Wire ${board_id} )
I saw an example with this library in the examples: https://github.com/arduino-cmake/Arduino-CMake-NG/tree/master/examples/platform-library
And tried to compile it: I get (besides other bugs): CMake Error at /home/user/projects/Arduinotest/Platform/Libraries/LibrariesFinder.cmake:38 (message): Couldn't find library named Wire
@gnthibault Hi there - What branch are you using? Is it a release?
@MrPointer I did used a release the latest I found from the github
@gnthibault Well that might explain it, as this bug is possibly already solved in the dev branch, which is master
in our case.
You can try and clone it to see if that solves your issue, but do note - The API has changed (quite significantly actually) and there's not much docs about it yet (As it hasn't been officially released).
With that being said, I will gladly lead your way through this process, as I still don't know when the new version is gonna come out.
@MrPointer I might be wrong, but I missed the functionality of "find_arduino_library" to add the directories of the header files to the include_directories list. Is it only me who can't use the framework properly, or there is no such functionality? I implemented it on my own. Would it make a sense to create a pull request of it, or it's less needed by others? Thanks, Zsolt
@ZsoltSaskovy I'm afraid I don't quite understand your precise intention. Please do open a PR, it'll be better to discuss it there.
I am trying to compile a slightly modified version of StandardFirmata arduino example sketch for arduino uno Here is my CMakeLists.txt:
The error is the following: