# The following lines of boilerplate have to be in your project's
# CMakeLists in this exact order for cmake to work correctly
cmake_minimum_required(VERSION 3.5)
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
set (EXTRA_COMPONENT_DIRS "$ENV{ESP_PATH}/esp-azure/port")
project(chaze-esp32)
Q: Can all the components include the files in the extra component, or do I have to register
that for every component that tries to use it?
In main.cpp, #include "iothub_message.h" succeeds, but not #include "upload_to_blob_block.h"
The reason seems to be that upload_to_blob_block.c can not find the include files.
I know that the required components, included in .c files must be listes in PRIV_REQUIRES, but how do I reference esp-azure, if it is not in my components directory?
This is the output when trying to compile it:
CMake Error at /home/julianbuchel2/esp/esp-idf/tools/cmake/component.cmake:283 (message):
Include directory '/esp-azure/port' is not a directory.
Call Stack (most recent call first):
/home/julianbuchel2/esp/esp-idf/tools/cmake/component.cmake:447 (__component_add_include_dirs)
components/upload_to_blob/CMakeLists.txt:1 (idf_component_register)
-- Configuring incomplete, errors occurred!
See also "/home/julianbuchel2/Documents/chaze-esp32/build/CMakeFiles/CMakeOutput.log".
FAILED: build.ninja
/usr/bin/cmake -H/home/julianbuchel2/Documents/chaze-esp32 -B/home/julianbuchel2/Documents/chaze-esp32/build
ninja: error: rebuilding 'build.ninja': subcommand failed
ninja failed with exit code 1
Hi,
I am trying to use a component, which requires including some files from esp-azure.
main/main.cpp:
main/CMakeLists.txt:
CMakeLists.txt:
Q: Can all the components include the files in the extra component, or do I have to register that for every component that tries to use it?
components/upload_to_blob/CMakeLists.txt:
In main.cpp,
#include "iothub_message.h"
succeeds, but not#include "upload_to_blob_block.h"
The reason seems to be that
upload_to_blob_block.c
can not find the include files. I know that the required components, included in .c files must be listes in PRIV_REQUIRES, but how do I reference esp-azure, if it is not in my components directory?This is the output when trying to compile it: