Closed KurtE closed 2 months ago
Do not want to causwe conflicts, but https://forum.arduino.cc/t/compilation-error-wiring-private-h-no-such-file-or-directory/1146752/2 Seems to have a more complete fix
#if defined(__has_include)
#if __has_include("wiring_private.h")
#include "wiring_private.h"
#endif // __has_include("wiring_private.h")
#else //defined(__has_include)
#include "wiring_private.h"
#endif //defined(__has_include)
Sounds good... Pushed up change
Closing out detritus
Some of the new Arduino cores do not include this file. This includes the cores for the Arduino UNO Rev 4.
The change is limited to use the __has_include() preprocessor stuff be used to limit when arduino_private.h is included.
Two ways to fix this. 1) add it specifically to a list of cores to not include it, like this file has #ifndef RASPI
Or use GCC __has_include to detect it and then include it. With Arduino this will not work well for library headers, as the library search stuff will not see this as a dependency and as such won't add the -I to command line to find it. But this file is in core which is always on the search path
I ran this modified version on the UNO R4 Minima with the graphictest example.