Closed
Description
Hi,
So I have been a bit annoyed by how complex this library is to use in PlatformIO and ESP-IDF, as mentioned here it is quite the chore to get it building. So first, I went another way and cobbled the files together using CMake instead (my env is ESP32cam and it is a esp32 target):
FILE(GLOB_RECURSE app_sources ${CMAKE_SOURCE_DIR}/examples/*.*)
FILE(GLOB espcam_sources ${CMAKE_SOURCE_DIR}/.pio/libdeps/ESP32cam/esp32-camera/target/*.*)
FILE(GLOB_RECURSE espcam_sources_esp32 ${CMAKE_SOURCE_DIR}/.pio/libdeps/ESP32cam/esp32-camera/target/esp32/*.*)
idf_component_register(
SRCS ${app_sources} ${espcam_sources} ${espcam_sources_esp32}
INCLUDE_DIRS ${CMAKE_SOURCE_DIR}/.pio/libdeps/ESP32cam/esp32-camera/target/jpeg_include
${CMAKE_SOURCE_DIR}/.pio/libdeps/ESP32cam/esp32-camera/target/private_include
)
I certainly did not like that solution, as it is just everything else than portable.
Instead, the easiest way for me was to be add an idf_component.yml-file and add esp32-camera as a simple dependency:
version: "0.1.0"
description: "Testing esp32-camera"
dependencies:
# Required IDF version
idf: ">=4.1"
esp32-camera:
git: https://github.com/espressif/esp32-camera
and a
REQUIRES esp32-cam
..to the CMakeLists.txt and it works? (or at least it builds)
So wouldn't the idf_component.yml path be much easier, or at least deserved to be mentioned, for most PlatformIO ESP-IDF users?
Metadata
Metadata
Assignees
Labels
No labels