[efr32] move to openthread/ot-efr32 (#6403)

This commit is contained in:
Jonathan Hui
2021-05-06 14:28:28 -07:00
committed by GitHub
parent 394739f3d8
commit 5078323d35
104 changed files with 12 additions and 16165 deletions
+1 -60
View File
@@ -46,17 +46,6 @@
#
# script/cmake-build ${platform} ${nrf_build_type} -D${option}=ON -D${option}=OFF
#
# Need to add BOARD when compiling efr32:
#
# script/cmake-build ${platform} -DBOARD=${EFR32 board}
#
# Example:
# script/cmake-build efr32mg21 -DBOARD=brd4180b
#
# To enable dynamic multiprotocol support on efr32:
#
# script/cmake-build ${platform} -DBOARD=${EFR32 board} -DDMP=ON
#
# Compile with the specified ninja build target:
#
# OT_CMAKE_NINJA_TARGET="ot-cli-ftd" script/cmake-build ${platform}
@@ -79,7 +68,7 @@ set -euxo pipefail
OT_CMAKE_NINJA_TARGET=${OT_CMAKE_NINJA_TARGET:-}
readonly OT_SRCDIR="$(pwd)"
readonly OT_PLATFORMS=(cc2538 efr32mg1 efr32mg12 efr32mg13 efr32mg21 nrf52811 nrf52833 nrf52840 simulation posix)
readonly OT_PLATFORMS=(cc2538 nrf52811 nrf52833 nrf52840 simulation posix)
readonly OT_NRF528XX_BUILD_TYPES=(UART_trans USB_trans_bl SPI_trans_NCP soft_crypto soft_crypto_threading)
readonly OT_POSIX_SIM_COMMON_OPTIONS=(
"-DOT_BORDER_AGENT=ON"
@@ -143,29 +132,6 @@ readonly OT_nrf52833_OPTIONS=(
readonly OT_nrf52840_OPTIONS=("${OT_nrf52833_OPTIONS[@]:0}")
readonly OT_efr32_OPTIONS=(
"-DOT_DIAGNOSTIC=ON"
"-DOT_EXTERNAL_HEAP=ON"
"-DOT_EXTERNAL_MBEDTLS=silabs-mbedtls"
"-DOT_BUILTIN_MBEDTLS_MANAGEMENT=OFF"
)
readonly OT_efr32mg1_OPTIONS=(
"${OT_efr32_OPTIONS[@]:0}"
)
readonly OT_efr32mg12_OPTIONS=(
"${OT_efr32_OPTIONS[@]:0}"
)
readonly OT_efr32mg13_OPTIONS=(
"${OT_efr32_OPTIONS[@]:0}"
)
readonly OT_efr32mg21_OPTIONS=(
"${OT_efr32_OPTIONS[@]:0}"
)
die()
{
echo " ** ERROR: Openthread CMake doesn't support platform \"$1\""
@@ -232,31 +198,6 @@ main()
cc2538)
options+=("-DCMAKE_TOOLCHAIN_FILE=examples/platforms/${platform}/arm-none-eabi.cmake" "-DCMAKE_BUILD_TYPE=MinSizeRel")
;;
efr32*)
options+=("-DCMAKE_TOOLCHAIN_FILE=examples/platforms/efr32/${platform}/arm-none-eabi.cmake")
case "${platform}" in
efr32mg1)
OT_CMAKE_NINJA_TARGET=("ot-rcp")
options+=("${OT_efr32mg1_OPTIONS[@]}")
;;
efr32mg12)
OT_CMAKE_NINJA_TARGET=("ot-rcp" "ot-cli-ftd" "ot-cli-mtd" "ot-ncp-ftd" "ot-ncp-mtd")
OT_CMAKE_NINJA_TARGET+=("sleepy-demo-ftd" "sleepy-demo-mtd")
options+=("${OT_efr32mg12_OPTIONS[@]}")
;;
efr32mg13)
OT_CMAKE_NINJA_TARGET=("ot-rcp" "ot-cli-ftd" "ot-cli-mtd" "ot-ncp-ftd" "ot-ncp-mtd")
OT_CMAKE_NINJA_TARGET+=("sleepy-demo-ftd" "sleepy-demo-mtd")
options+=("${OT_efr32mg13_OPTIONS[@]}")
;;
efr32mg21)
OT_CMAKE_NINJA_TARGET=("ot-rcp" "ot-cli-ftd" "ot-cli-mtd" "ot-ncp-ftd" "ot-ncp-mtd")
OT_CMAKE_NINJA_TARGET+=("sleepy-demo-ftd" "sleepy-demo-mtd")
options+=("${OT_efr32mg21_OPTIONS[@]}")
;;
esac
;;
nrf52811)
local_options+=("${OT_nrf52811_OPTIONS[@]}" "-DCMAKE_TOOLCHAIN_FILE=examples/platforms/nrf528xx/${platform}/arm-none-eabi.cmake" "-DCMAKE_BUILD_TYPE=Release")
case "${nrf_build_type}" in