/device_firmware/7_insights/main/app_main.c:36:10: fatal error: app_
insights.h: No such file or directory
#include "app_insights.h"
^~~~~~~~~~~~~~~~
compilation terminated.
代码从https://github.com/espressif/book-esp32c3-iot-projects/tree/main/device_firmware/7_insights下载
第7个例子:RainMaker Insights 示例在build时报错,缺少app_insights.h文件
Moderator: ESP_ZT
Re: 第7个例子:RainMaker Insights 示例在build时报错,缺少app_insights.h文件
你好,请问有按照 https://github.com/espressif/book-esp32 ... ADME_cn.md 这个文档进行编译吗?该头文件位于 esp-rainmaker/examples/common/app_insights/
我这边编译没有问题。
Code: Select all
$ git clone --recursive https://github.com/espressif/esp-rainmaker.git
$ cd esp-rainmaker
$ git checkout d4eb2f4fcab04fa625d502a12ece202d7d949c08
$ git submodule update --init --recursive
$ export RAIMAKER_PATH="$PWD"
Re: 第7个例子:RainMaker Insights 示例在build时报错,缺少app_insights.h文件
重新到https://github.com/espressif/esp-rainmaker.git下载了相关的代码,现在没有那个错误了,但出现了新的erros如下所示:
/esp-rainmaker/examples/common/app_insights/app_insights.c: In
function 'app_insights_enable':
/esp-rainmaker/examples/common/app_insights/app_insights.c:52:5
: error: implicit declaration of function 'esp_insights_mqtt_setup'; did you mea
n 'esp_insights_send_data'? [-Werror=implicit-function-declaration]
esp_insights_mqtt_setup(mqtt_config);
^~~~~~~~~~~~~~~~~~~~~~~
esp_insights_send_data
cc1.exe: some warnings being treated as errors
ninja: build stopped: subcommand failed.
ninja failed with exit code 1
/esp-rainmaker/examples/common/app_insights/app_insights.c: In
function 'app_insights_enable':
/esp-rainmaker/examples/common/app_insights/app_insights.c:52:5
: error: implicit declaration of function 'esp_insights_mqtt_setup'; did you mea
n 'esp_insights_send_data'? [-Werror=implicit-function-declaration]
esp_insights_mqtt_setup(mqtt_config);
^~~~~~~~~~~~~~~~~~~~~~~
esp_insights_send_data
cc1.exe: some warnings being treated as errors
ninja: build stopped: subcommand failed.
ninja failed with exit code 1
Re: 第7个例子:RainMaker Insights 示例在build时报错,缺少app_insights.h文件
rainmaker 的版本貌似不对,你有执行 git checkout d4eb2f4fcab04fa625d502a12ece202d7d949c08 然后执行 git submodule update --init --recursive 吗?
Re: 第7个例子:RainMaker Insights 示例在build时报错,缺少app_insights.h文件
可以了,执行 git submodule update --init --recursive以后,就可以正常build了。
Who is online
Users browsing this forum: No registered users and 6 guests