diff --git a/components/perfmon/CMakeLists.txt b/components/perfmon/CMakeLists.txt index 670f1c912b..590ac8bed0 100644 --- a/components/perfmon/CMakeLists.txt +++ b/components/perfmon/CMakeLists.txt @@ -1,6 +1,7 @@ -idf_build_get_property(target IDF_TARGET) -if(${target} STREQUAL "esp32c3" OR ${target} STREQUAL "esp32h2" OR ${target} STREQUAL "esp32c2") - return() +idf_build_get_property(arch IDF_TARGET_ARCH) + +if(NOT "${arch}" STREQUAL "xtensa") + return() endif() set(xtensa_perfmon_srcs "xtensa_perfmon_access.c"