Page 1 of 1

Cannot remove gcc '-I' options for esp-idf include directories.

Posted: Tue Mar 29, 2022 12:20 pm
by kneko715
I have three components.
- The first(A) is the default component 'main'.
- The second(B) is the component that abstract esp-idf.
- The last one(C) is the application only using the (B)'s api.

I want to prohibit accessing the header in esp-idf from (C).

In Cmakelist.txt, we configured as following.
- (A) REQUIRES (B) and (C).
- (B) PRIV_REQUIRES esp-idf components.
- (C) REQUIRES only (B).

But in compilation of (C), gcc '-I' option has the several include paths of esp-idf components.
To exclude the include paths of esp-idf, how can I describe CMakelist.txt for (C)?