diff --git a/lib/writers/lvgl/lv_font.js b/lib/writers/lvgl/lv_font.js index ca387bd..bb6e88d 100644 --- a/lib/writers/lvgl/lv_font.js +++ b/lib/writers/lvgl/lv_font.js @@ -77,10 +77,18 @@ class LvFont extends Font { * Opts: ${this.opts.opts_string} ******************************************************************************/ +#ifdef __has_include + #if __has_include("lvgl.h") + #ifndef LV_LVGL_H_INCLUDE_SIMPLE + #define LV_LVGL_H_INCLUDE_SIMPLE + #endif + #endif +#endif + #ifdef LV_LVGL_H_INCLUDE_SIMPLE -#include "lvgl.h" + #include "lvgl.h" #else -#include "${this.opts.lv_include || 'lvgl/lvgl.h'}" + #include "${this.opts.lv_include || 'lvgl/lvgl.h'}" #endif #ifndef ${guard_name}