diff --git a/benchmarks/coremark-pro/CMakeLists.txt b/benchmarks/coremark-pro/CMakeLists.txt index 5cd19227b..47b57535c 100644 --- a/benchmarks/coremark-pro/CMakeLists.txt +++ b/benchmarks/coremark-pro/CMakeLists.txt @@ -29,7 +29,7 @@ if(CONFIG_BENCHMARK_COREMARK_PRO) coremark_fetch URL https://github.com/eembc/coremark-pro/archive/refs/heads/main.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/coremark-pro BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/coremark/coremark-pro + ${NUTTX_BINARY_DIR}/apps/benchmarks/coremark/coremark-pro DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/benchmarks/coremark/CMakeLists.txt b/benchmarks/coremark/CMakeLists.txt index 3aef2967a..ce860cb3b 100644 --- a/benchmarks/coremark/CMakeLists.txt +++ b/benchmarks/coremark/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_BENCHMARK_COREMARK) coremark_fetch URL https://github.com/eembc/coremark/archive/main.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/coremark BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/coremark/coremark + ${NUTTX_BINARY_DIR}/apps/benchmarks/coremark/coremark DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/benchmarks/dhrystone/CMakeLists.txt b/benchmarks/dhrystone/CMakeLists.txt index 166692d36..500955d85 100644 --- a/benchmarks/dhrystone/CMakeLists.txt +++ b/benchmarks/dhrystone/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_BENCHMARK_DHRYSTONE) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/dhrystone BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/coremark/dhrystone + ${NUTTX_BINARY_DIR}/apps/benchmarks/coremark/dhrystone PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-dry2.2-Fix-malloc-type-mismatch.patch && diff --git a/benchmarks/fio/CMakeLists.txt b/benchmarks/fio/CMakeLists.txt index 5dae3f20d..c59887a0b 100644 --- a/benchmarks/fio/CMakeLists.txt +++ b/benchmarks/fio/CMakeLists.txt @@ -29,7 +29,7 @@ if(CONFIG_BENCHMARK_FIO) fio_fetch URL https://github.com/ldorau/fio/archive/refs/heads/master.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/fio BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/fio/fio + ${NUTTX_BINARY_DIR}/apps/benchmarks/fio/fio DOWNLOAD_NO_PROGRESS true TIMEOUT 30 PATCH_COMMAND diff --git a/benchmarks/superpi/CMakeLists.txt b/benchmarks/superpi/CMakeLists.txt index 7ab8ed611..a0796dd14 100644 --- a/benchmarks/superpi/CMakeLists.txt +++ b/benchmarks/superpi/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_BENCHMARK_SUPERPI) FetchContent_Declare( superpi_fetch URL ${SUPERPI_URL}/${SUPERPI_ZIP} SOURCE_DIR ${SUPERPI_UNPACK} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/superpi/superpi + ${NUTTX_BINARY_DIR}/apps/benchmarks/superpi/superpi DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/benchmarks/tacle-bench/CMakeLists.txt b/benchmarks/tacle-bench/CMakeLists.txt index f443d45cd..9a3cea2c8 100644 --- a/benchmarks/tacle-bench/CMakeLists.txt +++ b/benchmarks/tacle-bench/CMakeLists.txt @@ -1,24 +1,24 @@ -############################################################################ +# ############################################################################## # apps/benchmarks/tacle-bench/CMakeLists.txt # # SPDX-License-Identifier: Apache-2.0 # -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance with the -# License. You may obtain a copy of the License at +# Licensed to the Apache Software Foundation (ASF) under one or more contributor +# license agreements. See the NOTICE file distributed with this work for +# additional information regarding copyright ownership. The ASF licenses this +# file to you under the Apache License, Version 2.0 (the "License"); you may not +# use this file except in compliance with the License. You may obtain a copy of +# the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. +# License for the specific language governing permissions and limitations under +# the License. # -############################################################################ +# ############################################################################## if(CONFIG_BENCHMARK_TACLEBENCH) @@ -33,7 +33,7 @@ if(CONFIG_BENCHMARK_TACLEBENCH) FetchContent_Declare( taclebench_fetch URL ${TACLEBENCH_URL}/${TACLEBENCH_ZIP} SOURCE_DIR ${TACLEBENCH_UNPACK} - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/benchmarks/tacle-bench/tacle-bench + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/benchmarks/tacle-bench/tacle-bench PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-tacle-bench-add-makefile-and-all-in-one-main-file.patch diff --git a/benchmarks/test-tlb/CMakeLists.txt b/benchmarks/test-tlb/CMakeLists.txt index 866583e69..2f01500eb 100644 --- a/benchmarks/test-tlb/CMakeLists.txt +++ b/benchmarks/test-tlb/CMakeLists.txt @@ -1,24 +1,24 @@ -############################################################################ +# ############################################################################## # apps/benchmarks/test-tlb/CMakeLists.txt # # SPDX-License-Identifier: Apache-2.0 # -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance with the -# License. You may obtain a copy of the License at +# Licensed to the Apache Software Foundation (ASF) under one or more contributor +# license agreements. See the NOTICE file distributed with this work for +# additional information regarding copyright ownership. The ASF licenses this +# file to you under the Apache License, Version 2.0 (the "License"); you may not +# use this file except in compliance with the License. You may obtain a copy of +# the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. +# License for the specific language governing permissions and limitations under +# the License. # -############################################################################ +# ############################################################################## if(CONFIG_BENCHMARK_TESTTLB) set(SRCS test-tlb/test-tlb.c) @@ -32,7 +32,7 @@ if(CONFIG_BENCHMARK_TESTTLB) FetchContent_Declare( testtlb_fetch URL ${TESTTLB_URL}/${TESTTLB_ZIP} SOURCE_DIR ${TESTTLB_UNPACK} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/test-tlb/test-tlb + ${NUTTX_BINARY_DIR}/apps/benchmarks/test-tlb/test-tlb PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-test-tlb-port-for-NuttX.patch DOWNLOAD_NO_PROGRESS true diff --git a/benchmarks/tinymembench/CMakeLists.txt b/benchmarks/tinymembench/CMakeLists.txt index 1bbcf96ab..97a6c8274 100644 --- a/benchmarks/tinymembench/CMakeLists.txt +++ b/benchmarks/tinymembench/CMakeLists.txt @@ -1,24 +1,24 @@ -############################################################################ +# ############################################################################## # apps/benchmarks/tinymembench/CMakeLists.txt # # SPDX-License-Identifier: Apache-2.0 # -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance with the -# License. You may obtain a copy of the License at +# Licensed to the Apache Software Foundation (ASF) under one or more contributor +# license agreements. See the NOTICE file distributed with this work for +# additional information regarding copyright ownership. The ASF licenses this +# file to you under the Apache License, Version 2.0 (the "License"); you may not +# use this file except in compliance with the License. You may obtain a copy of +# the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. +# License for the specific language governing permissions and limitations under +# the License. # -############################################################################ +# ############################################################################## if(CONFIG_BENCHMARK_TINY_MEMBENCH) @@ -31,7 +31,7 @@ if(CONFIG_BENCHMARK_TINY_MEMBENCH) FetchContent_Declare( tinymb_fetch URL ${TINYMB_URL}/${TINYMB_ZIP} SOURCE_DIR ${TINYMB_UNPACK} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/benchmarks/tinymembench/tinymembench + ${NUTTX_BINARY_DIR}/apps/benchmarks/tinymembench/tinymembench PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-tinymembench-fix-compiling-error-for-NuttX.patch diff --git a/boot/mcuboot/CMakeLists.txt b/boot/mcuboot/CMakeLists.txt index 49c02a133..13ced0cef 100644 --- a/boot/mcuboot/CMakeLists.txt +++ b/boot/mcuboot/CMakeLists.txt @@ -32,7 +32,7 @@ if(CONFIG_BOOT_MCUBOOT) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/mcuboot BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/boot/mcuboot/mcuboot + ${NUTTX_BINARY_DIR}/apps/boot/mcuboot/mcuboot DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/canutils/lely-canopen/CMakeLists.txt b/canutils/lely-canopen/CMakeLists.txt index 8331511b1..2a8a5720e 100644 --- a/canutils/lely-canopen/CMakeLists.txt +++ b/canutils/lely-canopen/CMakeLists.txt @@ -35,7 +35,7 @@ if(CONFIG_CANUTILS_LELYCANOPEN) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/lely-core BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/canutils/lely-canopen/lely-core + ${NUTTX_BINARY_DIR}/apps/canutils/lely-canopen/lely-core PATCH_COMMAND patch -p1 -d ${CMAKE_CURRENT_LIST_DIR}/lely-core < ${CMAKE_CURRENT_LIST_DIR}/0001-tools-eliminate-multiple-definitions-of-poll-compile.patch diff --git a/canutils/libdronecan/CMakeLists.txt b/canutils/libdronecan/CMakeLists.txt index c8f7af9b2..a45902988 100644 --- a/canutils/libdronecan/CMakeLists.txt +++ b/canutils/libdronecan/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_CANUTILS_LIBDRONECAN) libdronecan_fetch URL ${CONFIG_LIBDRONECAN_URL}/${CONFIG_LIBDRONECAN_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libcanard BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/canutils/libdronecan/libcanard + ${NUTTX_BINARY_DIR}/apps/canutils/libdronecan/libcanard DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/canutils/libopencyphal/CMakeLists.txt b/canutils/libopencyphal/CMakeLists.txt index 3f0efee73..17bad8196 100644 --- a/canutils/libopencyphal/CMakeLists.txt +++ b/canutils/libopencyphal/CMakeLists.txt @@ -32,7 +32,7 @@ if(CONFIG_CANUTILS_LIBOPENCYPHAL) libcanard_fetch URL ${CONFIG_LIBOPENCYPHAL_URL}/${CONFIG_LIBOPENCYPHAL_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libcanard BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/canutils/libopencyphal/libcanard + ${NUTTX_BINARY_DIR}/apps/canutils/libopencyphal/libcanard DOWNLOAD_NO_PROGRESS true TIMEOUT 30) FetchContent_GetProperties(libcanard_fetch) @@ -47,7 +47,7 @@ if(CONFIG_CANUTILS_LIBOPENCYPHAL) o1heap_fetch URL ${CONFIG_O1HEAP_URL}/${CONFIG_O1HEAP_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/o1heap BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/canutils/libopencyphal/o1heap + ${NUTTX_BINARY_DIR}/apps/canutils/libopencyphal/o1heap DOWNLOAD_NO_PROGRESS true TIMEOUT 30) FetchContent_GetProperties(o1heap_fetch) diff --git a/cmake/nuttx_add_luamod.cmake b/cmake/nuttx_add_luamod.cmake index 93fefd628..e40e29d1d 100644 --- a/cmake/nuttx_add_luamod.cmake +++ b/cmake/nuttx_add_luamod.cmake @@ -20,7 +20,7 @@ # # ############################################################################## -set(LUAMOD_DIR ${CMAKE_BINARY_DIR}/luamod) +set(LUAMOD_DIR ${NUTTX_BINARY_DIR}/luamod) if(NOT EXISTS {LUAMOD_DIR}) file(MAKE_DIRECTORY ${LUAMOD_DIR}) diff --git a/cmake/nuttx_add_rust.cmake b/cmake/nuttx_add_rust.cmake index cfc527b9b..cb2067121 100644 --- a/cmake/nuttx_add_rust.cmake +++ b/cmake/nuttx_add_rust.cmake @@ -202,7 +202,7 @@ function(nuttx_add_rust) OUTPUT ${RUST_LIB_PATH} COMMAND ${CMAKE_COMMAND} -E env - NUTTX_INCLUDE_DIR=${PROJECT_SOURCE_DIR}/include:${CMAKE_BINARY_DIR}/include:${CMAKE_BINARY_DIR}/include/arch + NUTTX_INCLUDE_DIR=${PROJECT_SOURCE_DIR}/include:${NUTTX_BINARY_DIR}/include:${NUTTX_BINARY_DIR}/include/arch RUSTFLAGS=${RUST_PANIC_FLAGS} cargo build ${RUST_PROFILE_FLAG} -Zbuild-std=std,panic_abort -Zjson-target-spec --manifest-path ${CRATE_PATH}/Cargo.toml --target ${RUST_TARGET} --target-dir diff --git a/cmake/nuttx_add_wamrmod.cmake b/cmake/nuttx_add_wamrmod.cmake index 65f27c91c..d95b168cc 100644 --- a/cmake/nuttx_add_wamrmod.cmake +++ b/cmake/nuttx_add_wamrmod.cmake @@ -20,7 +20,7 @@ # # ############################################################################## -set(WAMR_MODULE_DIR ${CMAKE_BINARY_DIR}/wamrmod) +set(WAMR_MODULE_DIR ${NUTTX_BINARY_DIR}/wamrmod) if(NOT EXISTS {WAMR_MODULE_DIR}) file(MAKE_DIRECTORY ${WAMR_MODULE_DIR}) diff --git a/cmake/nuttx_wasm_interface.cmake b/cmake/nuttx_wasm_interface.cmake index 4e746f764..867325648 100644 --- a/cmake/nuttx_wasm_interface.cmake +++ b/cmake/nuttx_wasm_interface.cmake @@ -38,13 +38,13 @@ function(wasm_add_application) if(APP_INSTALL_NAME) add_custom_command( - OUTPUT ${CMAKE_BINARY_DIR}/wasm/${APP_INSTALL_NAME} + OUTPUT ${NUTTX_BINARY_DIR}/wasm/${APP_INSTALL_NAME} COMMAND ${CMAKE_COMMAND} -E touch_nocreate - ${CMAKE_BINARY_DIR}/wasm/${APP_INSTALL_NAME} + ${NUTTX_BINARY_DIR}/wasm/${APP_INSTALL_NAME} DEPENDS apps) add_custom_target(wasm_gen_${APP_NAME} - DEPENDS ${CMAKE_BINARY_DIR}/wasm/${APP_INSTALL_NAME}) - add_dynamic_rcraws(RAWS ${CMAKE_BINARY_DIR}/wasm/${APP_INSTALL_NAME} + DEPENDS ${NUTTX_BINARY_DIR}/wasm/${APP_INSTALL_NAME}) + add_dynamic_rcraws(RAWS ${NUTTX_BINARY_DIR}/wasm/${APP_INSTALL_NAME} DEPENDS wasm_gen_${APP_NAME}) endif() diff --git a/crypto/controlse/CMakeLists.txt b/crypto/controlse/CMakeLists.txt index 5ffa43cfd..36bd926c7 100644 --- a/crypto/controlse/CMakeLists.txt +++ b/crypto/controlse/CMakeLists.txt @@ -22,7 +22,7 @@ if(CONFIG_CRYPTO_CONTROLSE) - set(MBEDTLS_DIR ${CMAKE_BINARY_DIR}/apps/include/mbedtls) + set(MBEDTLS_DIR ${NUTTX_BINARY_DIR}/apps/include/mbedtls) nuttx_add_application( NAME diff --git a/crypto/libsodium/CMakeLists.txt b/crypto/libsodium/CMakeLists.txt index daf7b326b..9aab53ce5 100644 --- a/crypto/libsodium/CMakeLists.txt +++ b/crypto/libsodium/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_LIBSODIUM) libsodium_fetch URL ${LIBSODIUM_URL}/${CONFIG_LIBSODIUM_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libsodium BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/crypto/libsodium/libsodium + ${NUTTX_BINARY_DIR}/apps/crypto/libsodium/libsodium PATCH_COMMAND patch -p1 -d ${CMAKE_CURRENT_LIST_DIR}/libsodium < ${CMAKE_CURRENT_LIST_DIR}/0001-fix-multiple-definition-bug-in-libsodium-test.patch diff --git a/crypto/libtomcrypt/CMakeLists.txt b/crypto/libtomcrypt/CMakeLists.txt index d3fb2a5dc..0cf84a98a 100644 --- a/crypto/libtomcrypt/CMakeLists.txt +++ b/crypto/libtomcrypt/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_CRYPTO_LIBTOMCRYPT) libtomcrypt_fetch URL ${CONFIG_LIBTOMCRYPT_URL}/v${CONFIG_LIBTOMCRYPT_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libtomcrypt BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/crypto/libtomcrypt/libtomcrypt + ${NUTTX_BINARY_DIR}/apps/crypto/libtomcrypt/libtomcrypt PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/digit-bit.patch && patch -p0 -d diff --git a/crypto/mbedtls/CMakeLists.txt b/crypto/mbedtls/CMakeLists.txt index 478a257bd..b0a56be37 100644 --- a/crypto/mbedtls/CMakeLists.txt +++ b/crypto/mbedtls/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_CRYPTO_MBEDTLS) mbedtls_fetch URL ${MBEDTLS_URL}/v${CONFIG_MBEDTLS_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/mbedtls BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/crypto/mbedtls/mbedtls + ${NUTTX_BINARY_DIR}/apps/crypto/mbedtls/mbedtls PATCH_COMMAND patch -p1 -d ${MBEDTLS_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-mbedtls-entropy_poll-use-getrandom-to-get-the-system.patch diff --git a/crypto/tinycrypt/CMakeLists.txt b/crypto/tinycrypt/CMakeLists.txt index c75ae88c6..31b9324b8 100644 --- a/crypto/tinycrypt/CMakeLists.txt +++ b/crypto/tinycrypt/CMakeLists.txt @@ -36,7 +36,7 @@ if(CONFIG_TINYCRYPT) FetchContent_Declare( tinycrypt_fetch URL ${TINYCRYPT_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/tinycrypt - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/crypto/tinycrypt/tinycrypt + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/crypto/tinycrypt/tinycrypt PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR}/tinycrypt < ${CMAKE_CURRENT_LIST_DIR}/0001-TinyCrypt-test-resolve-compile-error.patch diff --git a/crypto/tinydtls/CMakeLists.txt b/crypto/tinydtls/CMakeLists.txt index 525422b4d..24fc04ecc 100644 --- a/crypto/tinydtls/CMakeLists.txt +++ b/crypto/tinydtls/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_CRYPTO_TINYDTLS) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/tinydtls BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/crypto/tinydtls/tinydtls + ${NUTTX_BINARY_DIR}/apps/crypto/tinydtls/tinydtls DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/examples/elf/main/CMakeLists.txt b/examples/elf/main/CMakeLists.txt index 3b354fe21..3ea5f7e83 100644 --- a/examples/elf/main/CMakeLists.txt +++ b/examples/elf/main/CMakeLists.txt @@ -28,7 +28,7 @@ if(CONFIG_EXAMPLES_ELF) set(ELF_BINARY_FILES) set(ELF_BINARY_TARGETS) foreach(ELFNAME IN LISTS ELFNAME_BASE) - list(APPEND ELF_BINARY_FILES ${CMAKE_BINARY_DIR}/bin/${ELFNAME}) + list(APPEND ELF_BINARY_FILES ${NUTTX_BINARY_DIR}/bin/${ELFNAME}) if(CMAKE_C_ELF_COMPILER) list(APPEND ELF_BINARY_TARGETS ${ELFNAME}) @@ -52,11 +52,11 @@ if(CONFIG_EXAMPLES_ELF) set(ELF_ROMFS_DEPS ${ELF_BINARY_TARGETS}) if(CONFIG_SYSTEM_NXPKG) - set(ELF_INDEX_JSON ${CMAKE_BINARY_DIR}/bin/index.json) - set(ELF_BAD_INDEX_JSON ${CMAKE_BINARY_DIR}/bin/bad-index.json) - set(ELF_PKGTEST ${CMAKE_BINARY_DIR}/bin/pkgtest.nsh) - set(ELF_PKGFAIL ${CMAKE_BINARY_DIR}/bin/pkgfail.nsh) - set(ELF_HELLO_BIN ${CMAKE_BINARY_DIR}/bin/hello) + set(ELF_INDEX_JSON ${NUTTX_BINARY_DIR}/bin/index.json) + set(ELF_BAD_INDEX_JSON ${NUTTX_BINARY_DIR}/bin/bad-index.json) + set(ELF_PKGTEST ${NUTTX_BINARY_DIR}/bin/pkgtest.nsh) + set(ELF_PKGFAIL ${NUTTX_BINARY_DIR}/bin/pkgfail.nsh) + set(ELF_HELLO_BIN ${NUTTX_BINARY_DIR}/bin/hello) set(ELF_FIXTURE_HOST_DIR ${CMAKE_CURRENT_BINARY_DIR}/host) set(ELF_FIXTURE_HOST_SRC ${CMAKE_CURRENT_SOURCE_DIR}/host/CMakeLists.txt) set(ELF_FIXTURE_TOOL @@ -99,7 +99,7 @@ if(CONFIG_EXAMPLES_ELF) add_custom_command( OUTPUT ${ELF_ROMFS_IMG} - COMMAND genromfs -f ${ELF_ROMFS_IMG} -d ${CMAKE_BINARY_DIR}/bin + COMMAND genromfs -f ${ELF_ROMFS_IMG} -d ${NUTTX_BINARY_DIR}/bin DEPENDS ${ELF_ROMFS_DEPS} VERBATIM) diff --git a/examples/nettest/CMakeLists.txt b/examples/nettest/CMakeLists.txt index fafdec236..47c99d7e9 100644 --- a/examples/nettest/CMakeLists.txt +++ b/examples/nettest/CMakeLists.txt @@ -49,7 +49,7 @@ if(CONFIG_EXAMPLES_NETTEST) SRCS nettest_target1.c INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx STACKSIZE ${CONFIG_EXAMPLES_NETTEST_STACKSIZE1} PRIORITY @@ -73,7 +73,7 @@ if(CONFIG_EXAMPLES_NETTEST) SRCS nettest_target2.c INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx STACKSIZE ${CONFIG_EXAMPLES_NETTEST_STACKSIZE2} PRIORITY @@ -81,7 +81,7 @@ if(CONFIG_EXAMPLES_NETTEST) endif() - target_include_directories(apps PRIVATE ${CMAKE_BINARY_DIR}/include/nuttx) + target_include_directories(apps PRIVATE ${NUTTX_BINARY_DIR}/include/nuttx) target_sources(apps PRIVATE ${SRCS}) # Host @@ -91,10 +91,10 @@ if(CONFIG_EXAMPLES_NETTEST) ExternalProject_Add( nettest SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/host - INSTALL_DIR ${CMAKE_BINARY_DIR}/apps/examples/nettest/host + INSTALL_DIR ${NUTTX_BINARY_DIR}/apps/examples/nettest/host CMAKE_ARGS - -DNUTTX_DIR=${NUTTX_DIR} -DNUTTX_BINARY_DIR=${CMAKE_BINARY_DIR} - -DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/apps/examples/nettest/host + -DNUTTX_DIR=${NUTTX_DIR} -DNUTTX_BINARY_DIR=${NUTTX_BINARY_DIR} + -DCMAKE_INSTALL_PREFIX=${NUTTX_BINARY_DIR}/apps/examples/nettest/host USES_TERMINAL_CONFIGURE true USES_TERMINAL_BUILD true USES_TERMINAL_INSTALL true) diff --git a/examples/sotest/main/CMakeLists.txt b/examples/sotest/main/CMakeLists.txt index 5c5cef5a6..154812bee 100644 --- a/examples/sotest/main/CMakeLists.txt +++ b/examples/sotest/main/CMakeLists.txt @@ -24,8 +24,8 @@ if(CONFIG_EXAMPLES_SOTEST) set(SOTEST_SYMTAB ${CMAKE_CURRENT_BINARY_DIR}/sotest_symtab.c) set(SOTEST_ROMFS_IMG ${CMAKE_CURRENT_BINARY_DIR}/sotest_romfs.img) set(SOTEST_ROMFS_SRC ${CMAKE_CURRENT_BINARY_DIR}/sotest_romfs.c) - set(SOTEST_MODPRINT_ELF ${CMAKE_BINARY_DIR}/bin/modprint) - set(SOTEST_SHARED_ELF ${CMAKE_BINARY_DIR}/bin/sotest) + set(SOTEST_MODPRINT_ELF ${NUTTX_BINARY_DIR}/bin/modprint) + set(SOTEST_SHARED_ELF ${NUTTX_BINARY_DIR}/bin/sotest) # Dynamic applications are wrapped in ELF_* helper targets when the build uses # the non-ELF-capable compiler path. @@ -52,8 +52,8 @@ if(CONFIG_EXAMPLES_SOTEST) set(SOTEST_ROMFS_DEPS ${SOTEST_MODPRINT_TARGET} ${SOTEST_SHARED_TARGET}) if(CONFIG_SYSTEM_NXPKG) - set(SOTEST_SHARED_INDEX ${CMAKE_BINARY_DIR}/bin/shared-index.json) - set(SOTEST_SHARED_SCRIPT ${CMAKE_BINARY_DIR}/bin/pkgsotest.nsh) + set(SOTEST_SHARED_INDEX ${NUTTX_BINARY_DIR}/bin/shared-index.json) + set(SOTEST_SHARED_SCRIPT ${NUTTX_BINARY_DIR}/bin/pkgsotest.nsh) set(SOTEST_FIXTURE_HOST_DIR ${CMAKE_CURRENT_BINARY_DIR}/host) set(SOTEST_FIXTURE_HOST_SRC ${CMAKE_CURRENT_SOURCE_DIR}/host/CMakeLists.txt) @@ -93,7 +93,7 @@ if(CONFIG_EXAMPLES_SOTEST) add_custom_command( OUTPUT ${SOTEST_ROMFS_IMG} - COMMAND genromfs -f ${SOTEST_ROMFS_IMG} -d ${CMAKE_BINARY_DIR}/bin + COMMAND genromfs -f ${SOTEST_ROMFS_IMG} -d ${NUTTX_BINARY_DIR}/bin DEPENDS ${SOTEST_ROMFS_DEPS} VERBATIM) diff --git a/examples/tcpblaster/CMakeLists.txt b/examples/tcpblaster/CMakeLists.txt index 5e72826c1..64921853a 100644 --- a/examples/tcpblaster/CMakeLists.txt +++ b/examples/tcpblaster/CMakeLists.txt @@ -55,7 +55,7 @@ if(CONFIG_EXAMPLES_TCPBLASTER) MODULE ${CONFIG_EXAMPLES_TCPBLASTER} INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx SRCS tcpblaster_target1.c ${CSRCS}) @@ -78,7 +78,7 @@ if(CONFIG_EXAMPLES_TCPBLASTER) MODULE ${CONFIG_EXAMPLES_TCPBLASTER} INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx SRCS tcpblaster_target2.c ${CSRCS}) diff --git a/examples/tcpblaster/tcpblaster_host.cmake b/examples/tcpblaster/tcpblaster_host.cmake index e2bf12e1a..1540fa51f 100644 --- a/examples/tcpblaster/tcpblaster_host.cmake +++ b/examples/tcpblaster/tcpblaster_host.cmake @@ -31,7 +31,7 @@ endif() message(STATUS "NuttX apps examples tcpblaster host") -include_directories(${CMAKE_BINARY_DIR}/include/nuttx) +include_directories(${NUTTX_BINARY_DIR}/include/nuttx) add_compile_definitions(TCPBLASTER_HOST=1) diff --git a/examples/udp/CMakeLists.txt b/examples/udp/CMakeLists.txt index b3cbdf166..4b5435956 100644 --- a/examples/udp/CMakeLists.txt +++ b/examples/udp/CMakeLists.txt @@ -48,7 +48,7 @@ if(CONFIG_EXAMPLES_UDP) MODULE ${CONFIG_EXAMPLES_UDP} INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx SRCS udp_target1.c ${CSRCS}) @@ -72,7 +72,7 @@ if(CONFIG_EXAMPLES_UDP) MODULE ${CONFIG_EXAMPLES_UDP} INCLUDE_DIRECTORIES - ${CMAKE_BINARY_DIR}/include/nuttx + ${NUTTX_BINARY_DIR}/include/nuttx SRCS udp_target2.c ${CSRCS}) diff --git a/examples/udpblaster/udpblaster_host.cmake b/examples/udpblaster/udpblaster_host.cmake index 769c8ded9..ac7698fc1 100644 --- a/examples/udpblaster/udpblaster_host.cmake +++ b/examples/udpblaster/udpblaster_host.cmake @@ -31,7 +31,7 @@ endif() message(STATUS "NuttX apps examples udpblaster host") -include_directories(${CMAKE_BINARY_DIR}/include/nuttx) +include_directories(${NUTTX_BINARY_DIR}/include/nuttx) add_compile_definitions(UDPBLASTER_HOST=1) add_library(udpblaster) diff --git a/fsutils/inih/CMakeLists.txt b/fsutils/inih/CMakeLists.txt index 7f8196623..4db7fe6d5 100644 --- a/fsutils/inih/CMakeLists.txt +++ b/fsutils/inih/CMakeLists.txt @@ -32,7 +32,7 @@ if(CONFIG_FSUTILS_INIH) FetchContent_Declare( inih_fetch URL ${INIH_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/inih-r42 BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/fsutils/inih/inih-r42 + ${NUTTX_BINARY_DIR}/apps/fsutils/inih/inih-r42 DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/graphics/libyuv/CMakeLists.txt b/graphics/libyuv/CMakeLists.txt index c792f090f..1cf0ccd68 100644 --- a/graphics/libyuv/CMakeLists.txt +++ b/graphics/libyuv/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_LIBYUV) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libyuv BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/graphics/libyuv/libyuv + ${NUTTX_BINARY_DIR}/apps/graphics/libyuv/libyuv PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-include-libyuv-fix-strict-prototype-warning.patch diff --git a/graphics/lvgl/CMakeLists.txt b/graphics/lvgl/CMakeLists.txt index ba5af28e2..c6ba90ef5 100644 --- a/graphics/lvgl/CMakeLists.txt +++ b/graphics/lvgl/CMakeLists.txt @@ -42,7 +42,7 @@ if(CONFIG_GRAPHICS_LVGL) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/lvgl BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/graphics/lvgl/lvgl + ${NUTTX_BINARY_DIR}/apps/graphics/lvgl/lvgl DOWNLOAD_NO_PROGRESS true TIMEOUT 120) diff --git a/inertial/madgwick/CMakeLists.txt b/inertial/madgwick/CMakeLists.txt index df20b7129..c6d482b45 100644 --- a/inertial/madgwick/CMakeLists.txt +++ b/inertial/madgwick/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_LIB_MADGWICK) SOURCE_DIR ${MADGWICK_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/inertial/madgwick/fusion + ${NUTTX_BINARY_DIR}/apps/inertial/madgwick/fusion DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/interpreters/berry/CMakeLists.txt b/interpreters/berry/CMakeLists.txt index d4749851b..6c95e1e3d 100644 --- a/interpreters/berry/CMakeLists.txt +++ b/interpreters/berry/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_INTERPRETERS_BERRY) berry_fetch URL ${BERRY_URL_BASE}/${BERRY_COMMIT_ID}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/berry BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/interpreters/berry/berry + ${NUTTX_BINARY_DIR}/apps/interpreters/berry/berry PATCH_COMMAND patch -l -p1 -d ${CMAKE_CURRENT_LIST_DIR}/berry -i ${CMAKE_CURRENT_LIST_DIR}/0001-Fix-Berry-default-port-for-NuttX.patch diff --git a/interpreters/jimtcl/CMakeLists.txt b/interpreters/jimtcl/CMakeLists.txt index c9df153f2..642787d33 100644 --- a/interpreters/jimtcl/CMakeLists.txt +++ b/interpreters/jimtcl/CMakeLists.txt @@ -43,7 +43,7 @@ if(CONFIG_INTERPRETERS_JIMTCL) "/^void Jim_SetEnviron/,/^/{s/\$/ *\\//}" jim.c CONFIGURE_COMMAND ./configure --host=${CMAKE_C_COMPILER_TARGET} - "CFLAGS=$, > -D$, -D> -I$, -I> -isystem ${CMAKE_SOURCE_DIR}/include -isystem ${CMAKE_BINARY_DIR}/include" + "CFLAGS=$, > -D$, -D> -I$, -I> -isystem ${NUTTX_DIR}/include -isystem ${NUTTX_BINARY_DIR}/include" BUILD_COMMAND make libjim.a initjimsh.o INSTALL_COMMAND "" BUILD_IN_SOURCE TRUE diff --git a/interpreters/lua/CMakeLists.txt b/interpreters/lua/CMakeLists.txt index 863c63514..fcd57cbca 100644 --- a/interpreters/lua/CMakeLists.txt +++ b/interpreters/lua/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_INTERPRETERS_LUA) lua_fetch URL ${LUA_URL}/v${CONFIG_INTERPRETERS_LUA_VERSION}.tar.gz SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/lua BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/interpreters/lua/lua + ${NUTTX_BINARY_DIR}/apps/interpreters/lua/lua DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/interpreters/quickjs/CMakeLists.txt b/interpreters/quickjs/CMakeLists.txt index e64c2d0c7..fc6e12c2d 100644 --- a/interpreters/quickjs/CMakeLists.txt +++ b/interpreters/quickjs/CMakeLists.txt @@ -30,7 +30,7 @@ if(CONFIG_INTERPRETERS_QUICKJS) quickjs_fetch URL ${QUICKJS_URL_BASE}/6e2e68fd0896957f92eb6c242a2e048c1ef3cae0.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/quickjs BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/interpreters/quickjs/quickjs + ${NUTTX_BINARY_DIR}/apps/interpreters/quickjs/quickjs PATCH_COMMAND patch -p1 -d ${CMAKE_CURRENT_LIST_DIR}/quickjs < ${CMAKE_CURRENT_LIST_DIR}/0001-Disabled-unsupported-feature-on-NuttX.patch diff --git a/interpreters/wamr/CMakeLists.txt b/interpreters/wamr/CMakeLists.txt index f155e61bf..0803dc98e 100644 --- a/interpreters/wamr/CMakeLists.txt +++ b/interpreters/wamr/CMakeLists.txt @@ -36,7 +36,7 @@ if(CONFIG_INTERPRETERS_WAMR) wamr_fetch URL ${WAMR_URL_BASE}/${CONFIG_INTERPRETERS_WAMR_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/wamr BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/interpreters/wamr/wamr + ${NUTTX_BINARY_DIR}/apps/interpreters/wamr/wamr DOWNLOAD_NO_PROGRESS true TIMEOUT 30) @@ -87,9 +87,9 @@ if(CONFIG_INTERPRETERS_WAMR) target_sources(wamr PRIVATE wamr_custom_init.c) endif() - # Add ${CMAKE_BINARY_DIR}/wamrmod to the include directories + # Add ${NUTTX_BINARY_DIR}/wamrmod to the include directories if(CONFIG_INTERPRETERS_WAMR_EXTERNAL_MODULE_REGISTRY) - target_include_directories(wamr PRIVATE ${CMAKE_BINARY_DIR}/wamrmod) + target_include_directories(wamr PRIVATE ${NUTTX_BINARY_DIR}/wamrmod) endif() endif() diff --git a/math/gemmlowp/CMakeLists.txt b/math/gemmlowp/CMakeLists.txt index b13b12794..b03871f66 100644 --- a/math/gemmlowp/CMakeLists.txt +++ b/math/gemmlowp/CMakeLists.txt @@ -35,7 +35,7 @@ if(CONFIG_MATH_GEMMLOWP) FetchContent_Declare( gemmlowp_fetch URL ${GEMMLOWP_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/gemmlowp - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/math/gemmlowp/gemmlowp + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/math/gemmlowp/gemmlowp DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/math/kissfft/CMakeLists.txt b/math/kissfft/CMakeLists.txt index 7273f0e09..062dc740e 100644 --- a/math/kissfft/CMakeLists.txt +++ b/math/kissfft/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_MATH_KISSFFT) FetchContent_Declare( kissfft_fetch URL ${KISSFFT_URL} SOURCE_DIR ${KISSFFT_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/math/kissfft/kissfft + ${NUTTX_BINARY_DIR}/apps/math/kissfft/kissfft PATCH_COMMAND patch -d ${KISSFFT_DIR} -p1 < ${CMAKE_CURRENT_LIST_DIR}/kissfft.patch DOWNLOAD_NO_PROGRESS true diff --git a/math/libtommath/CMakeLists.txt b/math/libtommath/CMakeLists.txt index 211c755e1..ea09645f5 100644 --- a/math/libtommath/CMakeLists.txt +++ b/math/libtommath/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_MATH_LIBTOMMATH) libtommath_fetch URL ${CONFIG_LIBTOMMATH_URL}/v${CONFIG_LIBTOMMATH_VERSION}.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libtommath BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/math/libtommath/libtommath + ${NUTTX_BINARY_DIR}/apps/math/libtommath/libtommath DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/math/ruy/CMakeLists.txt b/math/ruy/CMakeLists.txt index 79ac2ac2b..2b2f4824e 100644 --- a/math/ruy/CMakeLists.txt +++ b/math/ruy/CMakeLists.txt @@ -35,7 +35,7 @@ if(CONFIG_MATH_RUY) FetchContent_Declare( ruy_fetch URL ${RUY_URL} SOURCE_DIR ${RUY_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/math/ruy/ruy + ${NUTTX_BINARY_DIR}/apps/math/ruy/ruy DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/mlearning/cmsis-nn/CMakeLists.txt b/mlearning/cmsis-nn/CMakeLists.txt index e5997cb35..8db8c75d4 100644 --- a/mlearning/cmsis-nn/CMakeLists.txt +++ b/mlearning/cmsis-nn/CMakeLists.txt @@ -35,7 +35,7 @@ if(CONFIG_MLEARNING_CMSIS_NN) FetchContent_Declare( cmsis_nn_fetch URL ${CMSIS_NN_URL} SOURCE_DIR ${CMSIS_NN_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/mlearning/cmsis-nn/cmsis-nn + ${NUTTX_BINARY_DIR}/apps/mlearning/cmsis-nn/cmsis-nn DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/mlearning/tflite-micro/CMakeLists.txt b/mlearning/tflite-micro/CMakeLists.txt index e3a2830d1..a2756e7c9 100644 --- a/mlearning/tflite-micro/CMakeLists.txt +++ b/mlearning/tflite-micro/CMakeLists.txt @@ -35,7 +35,7 @@ if(CONFIG_TFLITEMICRO) FetchContent_Declare( tflite_micro_fetch URL ${TFLITE_MICRO_URL} SOURCE_DIR ${TFLITE_MICRO_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro + ${NUTTX_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro PATCH_COMMAND patch -d ${TFLITE_MICRO_DIR} -p1 < ${CMAKE_CURRENT_LIST_DIR}/tflite-micro.patch && patch -d @@ -182,7 +182,7 @@ if(CONFIG_TFLITEMICRO) function(tflite_generate_data in out declare) set(tflm_data_out - ${CMAKE_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro/${out}) + ${NUTTX_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro/${out}) if(NOT EXISTS ${tflm_data_out}) get_filename_component(TFLM_OUT ${tflm_data_out} DIRECTORY) if(NOT EXISTS ${TFLM_OUT}) @@ -244,7 +244,7 @@ if(CONFIG_TFLITEMICRO) ${TFLITE_MICRO_DIR}/tensorflow/lite/micro/examples/hello_world/hello_world_test.cc INCLUDE_DIRECTORIES ${INCDIR} - ${CMAKE_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro + ${NUTTX_BINARY_DIR}/apps/mlearning/tflite-micro/tflite-micro COMPILE_FLAGS ${COMMON_FLAGS}) endif() diff --git a/netutils/connectedhomeip/CMakeLists.txt b/netutils/connectedhomeip/CMakeLists.txt index 1031b4727..bc44cee31 100644 --- a/netutils/connectedhomeip/CMakeLists.txt +++ b/netutils/connectedhomeip/CMakeLists.txt @@ -78,7 +78,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/connectedhomeip BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 90 PATCH_LIST @@ -92,7 +92,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/pigweed BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 90) @@ -104,7 +104,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/nlio BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 30) @@ -116,7 +116,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/nlassert BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 30) @@ -128,7 +128,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/nlunit-test BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 30) @@ -140,7 +140,7 @@ if(CONFIG_MATTER) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/inipp BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip TIMEOUT 30) @@ -158,12 +158,12 @@ if(CONFIG_MATTER) list(APPEND nuttx_include_dirs ${include_dirs}) endif() list(APPEND nuttx_include_dirs ${NUTTX_DIR}/include - ${CMAKE_BINARY_DIR}/include) + ${NUTTX_BINARY_DIR}/include) list(APPEND nuttx_include_dirs ${NUTTX_APPS_BINDIR}/include/mbedtls) set(MATTER_INCDIR ${nuttx_include_dirs} - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip/gen/include + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip/gen/include ${NUTTX_APPS_DIR}/include ${NUTTX_APPS_DIR}/netutils/jsoncpp/jsoncpp/include inipp @@ -353,15 +353,15 @@ if(CONFIG_MATTER) 100) add_custom_command( - OUTPUT ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a + OUTPUT ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a COMMAND echo generate libchipnuttx.a) add_custom_target( libchipnuttx ALL - DEPENDS ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a + DEPENDS ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a ) add_dependencies(libchipnuttx chip-gn) nuttx_add_extra_library( - ${CMAKE_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a) + ${NUTTX_BINARY_DIR}/apps/netutils/connectedhomeip/lib/libchipnuttx.a) endif() diff --git a/netutils/jsoncpp/CMakeLists.txt b/netutils/jsoncpp/CMakeLists.txt index 3f8d17903..5af00f28a 100644 --- a/netutils/jsoncpp/CMakeLists.txt +++ b/netutils/jsoncpp/CMakeLists.txt @@ -30,7 +30,7 @@ if(CONFIG_NETUTILS_JSONCPP) FetchContent_Declare( jsoncpp_fetch URL ${JSONCPP_URL}/${JSONCPP_VERSION}.zip SOURCE_DIR ${JSONCPP_DIR} - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/netutils/jsoncpp + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/netutils/jsoncpp DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/libcoap/CMakeLists.txt b/netutils/libcoap/CMakeLists.txt index 404fd9956..5ca8da8aa 100644 --- a/netutils/libcoap/CMakeLists.txt +++ b/netutils/libcoap/CMakeLists.txt @@ -29,7 +29,7 @@ if(CONFIG_NETUTILS_LIBCOAP) FetchContent_Declare( libcoap_fetch URL ${LIBCOAP_URL}/v${LIBCOAP_VERSION} SOURCE_DIR ${LIBCOAP_DIR} - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/netutils/libcoap + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/netutils/libcoap DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/libwebsockets/CMakeLists.txt b/netutils/libwebsockets/CMakeLists.txt index 8f308e292..211da759c 100644 --- a/netutils/libwebsockets/CMakeLists.txt +++ b/netutils/libwebsockets/CMakeLists.txt @@ -39,7 +39,7 @@ if(CONFIG_NETUTILS_LIBWEBSOCKETS) libwebsockets_fetch URL ${LIBWEBSOCKETS_URL}/v${LWS_VERSION}.zip SOURCE_DIR ${LIBWEBSOCKETS_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/libwebsockets/libwebsockets + ${NUTTX_BINARY_DIR}/apps/netutils/libwebsockets/libwebsockets DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/nng/CMakeLists.txt b/netutils/nng/CMakeLists.txt index e4fc48cb3..45bda02ac 100644 --- a/netutils/nng/CMakeLists.txt +++ b/netutils/nng/CMakeLists.txt @@ -1,24 +1,24 @@ -############################################################################ +# ############################################################################## # apps/netutils/nng/CMakeLists.txt # # SPDX-License-Identifier: Apache-2.0 # -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance with the -# License. You may obtain a copy of the License at +# Licensed to the Apache Software Foundation (ASF) under one or more contributor +# license agreements. See the NOTICE file distributed with this work for +# additional information regarding copyright ownership. The ASF licenses this +# file to you under the Apache License, Version 2.0 (the "License"); you may not +# use this file except in compliance with the License. You may obtain a copy of +# the License at # -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. +# License for the specific language governing permissions and limitations under +# the License. # -############################################################################ +# ############################################################################## if(CONFIG_NETUTILS_NNG) @@ -33,7 +33,7 @@ if(CONFIG_NETUTILS_NNG) FetchContent_Declare( nng_fetch URL ${NNG_URL}/v${CONFIG_NETUTILS_NNG_VERSION}.tar.gz SOURCE_DIR - ${NNG_DIR} BINARY_DIR ${CMAKE_BINARY_DIR}/apps/netutils/nng/nng + ${NNG_DIR} BINARY_DIR ${NUTTX_BINARY_DIR}/apps/netutils/nng/nng DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/paho_mqtt/CMakeLists.txt b/netutils/paho_mqtt/CMakeLists.txt index d3360390b..0139fb8e8 100644 --- a/netutils/paho_mqtt/CMakeLists.txt +++ b/netutils/paho_mqtt/CMakeLists.txt @@ -38,7 +38,7 @@ if(CONFIG_LIB_MQTT5) FetchContent_Declare( paho_mqtt_fetch URL ${PAHO_MQTT_URL}/v${PAHO_MQTT_VERSION}.zip SOURCE_DIR ${PAHO_MQTT_DIR} - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/netutils/paho_mqtt/paho_mqtt + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/netutils/paho_mqtt/paho_mqtt DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/rtptools/CMakeLists.txt b/netutils/rtptools/CMakeLists.txt index 76c8a0ab4..418e3e82a 100644 --- a/netutils/rtptools/CMakeLists.txt +++ b/netutils/rtptools/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_NETUTILS_RTPTOOLS) rtptools_fetch URL ${RTPTOOLS_URL}/${CONFIG_NETUTILS_RTPTOOLS_VERSION}.tar.gz SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/rtptools BINARY_DIR - ${CMAKE_BINARY_DIR}/netutils/rtptools/rtptools + ${NUTTX_BINARY_DIR}/netutils/rtptools/rtptools DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/netutils/wakaama/CMakeLists.txt b/netutils/wakaama/CMakeLists.txt index 6e5e4f094..d37be635c 100644 --- a/netutils/wakaama/CMakeLists.txt +++ b/netutils/wakaama/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_NETUTILS_WAKAAMA) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/wakaama BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/netutils/wakaama/wakaama + ${NUTTX_BINARY_DIR}/apps/netutils/wakaama/wakaama DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/system/adb/CMakeLists.txt b/system/adb/CMakeLists.txt index e13f6f83e..8a1bb4572 100644 --- a/system/adb/CMakeLists.txt +++ b/system/adb/CMakeLists.txt @@ -36,7 +36,7 @@ if(CONFIG_SYSTEM_ADBD) microADB URL "${ADBD_URL}/${ADBD_VERSION}.zip" SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/microADB BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/system/microADB/microADB + ${NUTTX_BINARY_DIR}/apps/system/microADB/microADB DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/system/argtable3/CMakeLists.txt b/system/argtable3/CMakeLists.txt index 40d322f60..5531b30c9 100644 --- a/system/argtable3/CMakeLists.txt +++ b/system/argtable3/CMakeLists.txt @@ -42,7 +42,7 @@ if(CONFIG_SYSTEM_ARGTABLE3) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/argtable3 BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/system/argtable3/argtable3 + ${NUTTX_BINARY_DIR}/apps/system/argtable3/argtable3 DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/system/flatbuffers/CMakeLists.txt b/system/flatbuffers/CMakeLists.txt index bbfc68421..c5d89a561 100644 --- a/system/flatbuffers/CMakeLists.txt +++ b/system/flatbuffers/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_SYSTEM_FLATBUFFERS) FetchContent_Declare( flatbuffers_fetch URL ${FLATBUFFERS_URL} SOURCE_DIR ${FLATBUFFERS_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/math/flatbuffers/flatbuffers + ${NUTTX_BINARY_DIR}/apps/math/flatbuffers/flatbuffers PATCH_COMMAND patch -d ${FLATBUFFERS_DIR} -p1 < ${CMAKE_CURRENT_LIST_DIR}/flatbuffers.patch DOWNLOAD_NO_PROGRESS true diff --git a/system/libuv/CMakeLists.txt b/system/libuv/CMakeLists.txt index 5364fb959..ce289a64b 100644 --- a/system/libuv/CMakeLists.txt +++ b/system/libuv/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_LIBUV) FetchContent_Declare( libuv_fetch URL ${LIBUV_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/libuv BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/system/libuv/libuv + ${NUTTX_BINARY_DIR}/apps/system/libuv/libuv PATCH_COMMAND patch -p1 -d ${CMAKE_CURRENT_LIST_DIR}/libuv < ${CMAKE_CURRENT_LIST_DIR}/0001-libuv-port-for-nuttx.patch DOWNLOAD_NO_PROGRESS true diff --git a/system/nxdiag/CMakeLists.txt b/system/nxdiag/CMakeLists.txt index ec0cd116c..72d513c91 100644 --- a/system/nxdiag/CMakeLists.txt +++ b/system/nxdiag/CMakeLists.txt @@ -73,7 +73,7 @@ if(CONFIG_SYSTEM_NXDIAG) add_custom_command( OUTPUT ${NXDIAG_SYSINFO} COMMAND ${PYTHON3} ${NXDIAG_PY_FLAGS} ${NXDIAG_TOOLSDIR}/host_info_dump.py - ${NXDIAG_FLAGS} -b ${CMAKE_BINARY_DIR} > ${NXDIAG_SYSINFO} + ${NXDIAG_FLAGS} -b ${NUTTX_BINARY_DIR} > ${NXDIAG_SYSINFO} DEPENDS ${NXDIAG_TOOLSDIR}/host_info_dump.py COMMENT "Generating nxdiag sysinfo.h" VERBATIM) @@ -95,7 +95,7 @@ if(CONFIG_SYSTEM_NXDIAG) nxdiag_sysinfo_gen) set_property( - DIRECTORY ${CMAKE_SOURCE_DIR} + DIRECTORY ${NUTTX_DIR} APPEND PROPERTY ADDITIONAL_CLEAN_FILES ${NXDIAG_SYSINFO}) diff --git a/system/zlib/CMakeLists.txt b/system/zlib/CMakeLists.txt index c326aef57..072134047 100644 --- a/system/zlib/CMakeLists.txt +++ b/system/zlib/CMakeLists.txt @@ -34,7 +34,7 @@ if(CONFIG_LIB_ZLIB) FetchContent_Declare( zlib_fetch URL ${ZLIB_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/zlib BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/system/zlib/zlib + ${NUTTX_BINARY_DIR}/apps/system/zlib/zlib DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/tee/optee_client/CMakeLists.txt b/tee/optee_client/CMakeLists.txt index a1f8cde36..c00d08137 100644 --- a/tee/optee_client/CMakeLists.txt +++ b/tee/optee_client/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_LIBTEEC) optee_client_fetch URL ${OPTEE_CLIENT_URL}/${OPTEE_CLIENT_VER}.zip SOURCE_DIR ${OPTEE_CLIENT_DIR} BINARY_DIR - ${CMAKE_BINARY_DIR}/tee/optee_client/optee_client + ${NUTTX_BINARY_DIR}/tee/optee_client/optee_client PATCH_COMMAND patch -p1 -d ${OPTEE_CLIENT_DIR} < ${CMAKE_CURRENT_LIST_DIR}/0001-libteec-NuttX.patch && patch -p1 -d diff --git a/testing/cmocka/CMakeLists.txt b/testing/cmocka/CMakeLists.txt index d810aee89..5051f23e6 100644 --- a/testing/cmocka/CMakeLists.txt +++ b/testing/cmocka/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_TESTING_CMOCKA) cmocka_fetch URL ${CONFIG_CMOCKA_URL}/1.1.5.zip SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/cmocka BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/testing/cmocka/cmocka + ${NUTTX_BINARY_DIR}/apps/testing/cmocka/cmocka PATCH_COMMAND patch -p1 -d ${CMAKE_CURRENT_LIST_DIR}/cmocka < ${CMAKE_CURRENT_LIST_DIR}/0001-cmocka.c-Reduce-the-call-stack-consumption-of-printf.patch diff --git a/testing/drivers/rng/nist-sts/CMakeLists.txt b/testing/drivers/rng/nist-sts/CMakeLists.txt index 7b2a9da79..8bfb3fee5 100644 --- a/testing/drivers/rng/nist-sts/CMakeLists.txt +++ b/testing/drivers/rng/nist-sts/CMakeLists.txt @@ -33,7 +33,7 @@ if(CONFIG_TESTING_NIST_STS) nist-sts_fetch URL ${CONFIG_NIST_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/nist-sts BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/testing/drivers/rng/nist-sts/nist-sts + ${NUTTX_BINARY_DIR}/apps/testing/drivers/rng/nist-sts/nist-sts PATCH_COMMAND patch -p0 -d ${CMAKE_CURRENT_LIST_DIR}/nist-sts < ${CMAKE_CURRENT_LIST_DIR}/0001-Solve-the-memory-out-of-bounds-problem-in-sts.patch diff --git a/testing/fff/CMakeLists.txt b/testing/fff/CMakeLists.txt index fdd1ccd58..525d4db88 100644 --- a/testing/fff/CMakeLists.txt +++ b/testing/fff/CMakeLists.txt @@ -30,7 +30,7 @@ if(CONFIG_TESTING_FFF) FetchContent_Declare( fff_fetch URL ${FFF_URL} SOURCE_DIR ${FFF_UNPACK} BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/testing/fff/fff + ${NUTTX_BINARY_DIR}/apps/testing/fff/fff DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/testing/ltp/CMakeLists.txt b/testing/ltp/CMakeLists.txt index 8d4674ecd..c3a82f1b8 100644 --- a/testing/ltp/CMakeLists.txt +++ b/testing/ltp/CMakeLists.txt @@ -36,7 +36,7 @@ if(CONFIG_TESTING_LTP) DOWNLOAD_DIR ${CMAKE_CURRENT_LIST_DIR} URL "${LTP_DOWNLOAD_URL}${LTPS_VERSION}.zip" SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/ltp BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/testing/ltp/ltp + ${NUTTX_BINARY_DIR}/apps/testing/ltp/ltp PATCH_COMMAND patch -p1 -d ${LTP_UNPACK} < ${CMAKE_CURRENT_LIST_DIR}/0001-pthread_rwlock_unlock-follow-linux.patch diff --git a/testing/mm/memtester/CMakeLists.txt b/testing/mm/memtester/CMakeLists.txt index 74d99b9d0..11504c0a5 100644 --- a/testing/mm/memtester/CMakeLists.txt +++ b/testing/mm/memtester/CMakeLists.txt @@ -31,7 +31,7 @@ if(CONFIG_UTILS_MEMTESTER) FetchContent_Declare( memtester_fetch URL ${CONFIG_MEMTESTER_URL} SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/memtester - BINARY_DIR ${CMAKE_BINARY_DIR}/apps/testing/memtester/memtester + BINARY_DIR ${NUTTX_BINARY_DIR}/apps/testing/memtester/memtester DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/testing/mm/stressapptest/CMakeLists.txt b/testing/mm/stressapptest/CMakeLists.txt index 397760397..8fb942f2e 100644 --- a/testing/mm/stressapptest/CMakeLists.txt +++ b/testing/mm/stressapptest/CMakeLists.txt @@ -36,7 +36,7 @@ if(CONFIG_TESTING_STRESSAPPTEST) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/stressapptest BINARY_DIR - ${CMAKE_BINARY_DIR}/stressapptest + ${NUTTX_BINARY_DIR}/stressapptest DOWNLOAD_NO_PROGRESS true TIMEOUT 30) diff --git a/testing/unity/CMakeLists.txt b/testing/unity/CMakeLists.txt index a52dd5745..855104c56 100644 --- a/testing/unity/CMakeLists.txt +++ b/testing/unity/CMakeLists.txt @@ -30,7 +30,7 @@ if(CONFIG_TESTING_UNITY) DOWNLOAD_DIR ${CMAKE_CURRENT_LIST_DIR} URL "${CONFIG_TESTING_UNITY_URL}/v${CONFIG_TESTING_UNITY_VERSION}.tar.gz" SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/Unity BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/testing/unity/unity + ${NUTTX_BINARY_DIR}/apps/testing/unity/unity DOWNLOAD_NO_PROGRESS true TIMEOUT 30) @@ -50,7 +50,7 @@ if(CONFIG_TESTING_UNITY) # allow use of like for make build file(COPY ${CMAKE_CURRENT_LIST_DIR}/Unity/src/unity.h ${CMAKE_CURRENT_LIST_DIR}/Unity/src/unity_internals.h - DESTINATION ${CMAKE_BINARY_DIR}/include/testing/) + DESTINATION ${NUTTX_BINARY_DIR}/include/testing/) target_sources(unity PRIVATE ${SRCS}) diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 640b597e1..11c355289 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -25,11 +25,11 @@ if(CONFIG_TOOLS_WASM_BUILD OR CONFIG_INTERPRETERS_WAMR_BUILD_MODULES_FOR_NUTTX) include(ExternalProject) set(TOPDIR - ${CMAKE_SOURCE_DIR} + ${NUTTX_DIR} CACHE INTERNAL "") set(KCONFIG_FILE_PATH - ${CMAKE_BINARY_DIR}/.config + ${NUTTX_BINARY_DIR}/.config CACHE INTERNAL "") # Get parent dir of CMAKE_CURRENT_SOURCE_DIR @@ -47,13 +47,13 @@ if(CONFIG_TOOLS_WASM_BUILD OR CONFIG_INTERPRETERS_WAMR_BUILD_MODULES_FOR_NUTTX) add_custom_target( configure_wasm_build COMMAND - ${CMAKE_COMMAND} -B${CMAKE_BINARY_DIR}/Wasm + ${CMAKE_COMMAND} -B${NUTTX_BINARY_DIR}/Wasm ${CMAKE_CURRENT_SOURCE_DIR}/Wasm -DAPPDIR=${APPDIR} -DTOPDIR=${TOPDIR} - -DTOPBINDIR=${CMAKE_BINARY_DIR} -DKCONFIG_FILE_PATH=${KCONFIG_FILE_PATH} + -DTOPBINDIR=${NUTTX_BINARY_DIR} -DKCONFIG_FILE_PATH=${KCONFIG_FILE_PATH} -DWASI_SDK_PATH=$ENV{WASI_SDK_PATH} -DWASM_DIRS="${WASM_DIRS}") add_custom_target(wasm_build COMMAND ${CMAKE_COMMAND} --build - ${CMAKE_BINARY_DIR}/Wasm) + ${NUTTX_BINARY_DIR}/Wasm) add_dependencies(wasm_build configure_wasm_build) diff --git a/wireless/bluetooth/nimble/CMakeLists.txt b/wireless/bluetooth/nimble/CMakeLists.txt index f6fda14ec..d8b6596b0 100644 --- a/wireless/bluetooth/nimble/CMakeLists.txt +++ b/wireless/bluetooth/nimble/CMakeLists.txt @@ -32,7 +32,7 @@ if(CONFIG_NIMBLE) SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/mynewt-nimble BINARY_DIR - ${CMAKE_BINARY_DIR}/apps/wireless/bluetooth/nimble/mynewt-nimble + ${NUTTX_BINARY_DIR}/apps/wireless/bluetooth/nimble/mynewt-nimble DOWNLOAD_NO_PROGRESS true TIMEOUT 30)