Skip to content

Commit 019e3de

Browse files
committed
modules: hal_nordic: allow BSP paths outside nrfx
BSP path override can be used to place it outside nrfx. Signed-off-by: Marcin Szymczyk <[email protected]>
1 parent d9c8651 commit 019e3de

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

modules/hal_nordic/nrfx/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,13 @@ endif()
1818
set(INC_DIR ${NRFX_DIR}/drivers/include)
1919
set(SRC_DIR ${NRFX_DIR}/drivers/src)
2020
set(HELPERS_DIR ${NRFX_DIR}/helpers)
21-
set(BSP_DIR ${NRFX_DIR}/bsp/${CONFIG_SOC_NORDIC_BSP_NAME})
21+
22+
if(DEFINED CONFIG_SOC_NORDIC_BSP_PATH_OVERRIDE)
23+
set(BSP_DIR ${ZEPHYR_CURRENT_MODULE_DIR}/${CONFIG_SOC_NORDIC_BSP_PATH_OVERRIDE}/${CONFIG_SOC_NORDIC_BSP_NAME})
24+
else()
25+
set(BSP_DIR ${NRFX_DIR}/bsp/${CONFIG_SOC_NORDIC_BSP_NAME})
26+
endif()
27+
2228
set(MDK_DIR ${BSP_DIR}/mdk)
2329

2430
zephyr_include_directories(${NRFX_DIR})

0 commit comments

Comments
 (0)