From 861517ecb09ba53be1fe8cb892a846264c52fc05 Mon Sep 17 00:00:00 2001 From: Leonardo Bispo <34199302+ldab@users.noreply.github.com> Date: Sun, 19 Feb 2023 13:16:15 +0100 Subject: [PATCH] component path relative to IDF Change the component path to relative to the IDF as the build will fail if the example is moved from its folder. (cherry picked from commit 4011f5ce595d114c69c46298088440a230eed937) Signed-off-by: Rahul Tank --- examples/bluetooth/nimble/ble_periodic_adv/CMakeLists.txt | 2 +- examples/bluetooth/nimble/ble_periodic_sync/CMakeLists.txt | 2 +- examples/bluetooth/nimble/blecent/CMakeLists.txt | 2 +- examples/bluetooth/nimble/bleprph/CMakeLists.txt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/bluetooth/nimble/ble_periodic_adv/CMakeLists.txt b/examples/bluetooth/nimble/ble_periodic_adv/CMakeLists.txt index a143c9dd24..a11db0a8cb 100644 --- a/examples/bluetooth/nimble/ble_periodic_adv/CMakeLists.txt +++ b/examples/bluetooth/nimble/ble_periodic_adv/CMakeLists.txt @@ -1,7 +1,7 @@ # The following lines of boilerplate have to be in your project's # CMakeLists in this exact order for cmake to work correctly cmake_minimum_required(VERSION 3.16) -set(EXTRA_COMPONENT_DIRS ${CMAKE_CURRENT_LIST_DIR}/../common/nimble_peripheral_utils) +set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/bluetooth/nimble/common/nimble_peripheral_utils) include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(ble_periodic_adv) diff --git a/examples/bluetooth/nimble/ble_periodic_sync/CMakeLists.txt b/examples/bluetooth/nimble/ble_periodic_sync/CMakeLists.txt index 12971ca736..0cfa53d6f5 100644 --- a/examples/bluetooth/nimble/ble_periodic_sync/CMakeLists.txt +++ b/examples/bluetooth/nimble/ble_periodic_sync/CMakeLists.txt @@ -1,6 +1,6 @@ # The following lines of boilerplate have to be in your project's # CMakeLists in this exact order for cmake to work correctly cmake_minimum_required(VERSION 3.16) -set(EXTRA_COMPONENT_DIRS ${CMAKE_CURRENT_LIST_DIR}/../common/nimble_central_utils) +set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/bluetooth/nimble/common/nimble_central_utils) include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(ble_periodic_sync) diff --git a/examples/bluetooth/nimble/blecent/CMakeLists.txt b/examples/bluetooth/nimble/blecent/CMakeLists.txt index 6b337e7c82..06382888f1 100644 --- a/examples/bluetooth/nimble/blecent/CMakeLists.txt +++ b/examples/bluetooth/nimble/blecent/CMakeLists.txt @@ -2,7 +2,7 @@ # CMakeLists in this exact order for cmake to work correctly cmake_minimum_required(VERSION 3.16) -set(EXTRA_COMPONENT_DIRS ${CMAKE_CURRENT_LIST_DIR}/../common/nimble_central_utils) +set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/bluetooth/nimble/common/nimble_central_utils) include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(blecent) diff --git a/examples/bluetooth/nimble/bleprph/CMakeLists.txt b/examples/bluetooth/nimble/bleprph/CMakeLists.txt index 1156a75370..59f9534623 100644 --- a/examples/bluetooth/nimble/bleprph/CMakeLists.txt +++ b/examples/bluetooth/nimble/bleprph/CMakeLists.txt @@ -2,7 +2,7 @@ # CMakeLists in this exact order for cmake to work correctly cmake_minimum_required(VERSION 3.16) -set(EXTRA_COMPONENT_DIRS ${CMAKE_CURRENT_LIST_DIR}/../common/nimble_peripheral_utils) +set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/bluetooth/nimble/common/nimble_peripheral_utils) include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(bleprph)