Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmake environment does not support COMPONENT_EXTRA_INCLUDES and COMPONENT_BUILD_DIR (GIT8266O-369) #803

Open
THKDev opened this issue Jan 5, 2020 · 0 comments

Comments

@THKDev
Copy link

THKDev commented Jan 5, 2020

Environment

  • Development Kit: ESP8266
  • IDF version: d1cfba3 (branch v3.3)
  • Development Env: CMake
  • Operating System: Linux
  • Power Supply: external 3.3V|

Problem Description

Regarding to build-system.rst documentation variables COMPONENT_EXTRA_INCLUDES and COMPONENT_BUILD_DIR should be used for component specific settings. This is fully working with component.mk. But this won't work within CMakeLists.txt for the same component.

Code to reproduce this issue

Sample component.mk

#
# "main" pseudo-component makefile.
#
# (Uses default behaviour of compiling all source files in directory, adding 'include' to include path.)

COMPONENT_EXTRA_INCLUDES=$(COMPONENT_BUILD_DIR)/generated

Sample CMakeLists.txt

# https://cmake.org/cmake/help/latest/module/CMakePrintHelpers.html
include(${CMAKE_ROOT}/Modules/CMakePrintHelpers.cmake)

set(COMPONENT_SRCS "main.cc")
set(COMPONENT_ADD_INCLUDEDIRS "include")
set(COMPONENT_EXTRA_INCLUDES "${COMPONENT_BUILD_DIR}/generated")

cmake_print_variables(COMPONENT_EXTRA_INCLUDES COMPONENT_BUILD_DIR)

register_component()
@github-actions github-actions bot changed the title cmake environment does not support COMPONENT_EXTRA_INCLUDES and COMPONENT_BUILD_DIR cmake environment does not support COMPONENT_EXTRA_INCLUDES and COMPONENT_BUILD_DIR (GIT8266O-369) Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant