diff --git a/CMakeLists.txt b/CMakeLists.txt index eeb3fbbc..b4fb4b5d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -4,7 +4,9 @@ # This CMake file is picked by the Zephyr build system because it is defined # as the module CMake entry point (see zephyr/module.yml). -zephyr_include_directories(include) +if (CONFIG_ZIGBEE_ADD_ON) + zephyr_include_directories(include) -add_subdirectory(lib) -add_subdirectory(subsys) + add_subdirectory(lib) + add_subdirectory(subsys) +endif() diff --git a/subsys/CMakeLists.txt b/subsys/CMakeLists.txt index f1525c5b..fe1400e0 100644 --- a/subsys/CMakeLists.txt +++ b/subsys/CMakeLists.txt @@ -37,7 +37,5 @@ zephyr_library_link_libraries(zboss) zephyr_compile_definitions(CUSTOM_IEEE802154_L2=ZIGBEE_L2) zephyr_compile_definitions(ZIGBEE_L2=ZIGBEE_ADD_ON) -if (CONFIG_ZIGBEE_ADD_ON) - include(${ZEPHYR_NRF_MODULE_DIR}/cmake/extensions.cmake) - ncs_add_partition_manager_config(partition_manager/pm.yml.zboss) -endif() +include(${ZEPHYR_NRF_MODULE_DIR}/cmake/extensions.cmake) +ncs_add_partition_manager_config(partition_manager/pm.yml.zboss)