Skip to content

Commit eb3f13b

Browse files
committed
cmake: Moved the creation of the nxtmpdir folder to the root CMake file
- Moved the creation of the `nxtmpdir` folder for third-party packages to the root `CMakeLists.txt` file. Signed-off-by: simbit18 <simbit18@gmail.com>
1 parent 791ec93 commit eb3f13b

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,13 @@ set(ENV{HOST_OTHER} n)
230230

231231
include(nuttx_sethost)
232232

233+
option(NXTMPDIR "Create the nxtmpdir folder for third-party packages." OFF)
234+
235+
if(NXTMPDIR)
236+
include(nuttx_3rdparty)
237+
nuttx_make_nxtmpdir()
238+
endif()
239+
233240
include(nuttx_parse_function_args)
234241
include(nuttx_add_subdirectory)
235242
include(nuttx_create_symlink)

arch/risc-v/src/common/espressif/CMakeLists.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,8 +243,6 @@ if(NOT IS_DIRECTORY "${ESP_HAL_3RDPARTY_REPO}")
243243
# NXTMPDIR contains a cached version of the esp-hal-3rdparty repository, which
244244
# is located on nuttx/../nxtmpdir/esp-hal-3rdparty if it exists.
245245
if(NXTMPDIR)
246-
include(${NUTTX_DIR}/cmake/nuttx_3rdparty.cmake)
247-
nuttx_make_nxtmpdir()
248246
set(ESP_HAL_NXTMPDIR_CACHE "${NXTMPDIR_PATH}/${ESP_HAL_3RDPARTY_REPO_NAME}")
249247
get_filename_component(ESP_HAL_NXTMPDIR_CACHE "${ESP_HAL_NXTMPDIR_CACHE}"
250248
REALPATH)

0 commit comments

Comments
 (0)