remove associative array and for loops to init submoduls

This commit is contained in:
lod 2024-10-21 13:27:20 +02:00
parent 856871f6cb
commit 3a307255fc

View file

@ -50,20 +50,24 @@ prepare() {
sed -i "s/if(${pattern}_FOUND)/if(false)/g" ./companion/src/CMakeLists.txt sed -i "s/if(${pattern}_FOUND)/if(false)/g" ./companion/src/CMakeLists.txt
done done
declare -A submodules=( cd "$_pkgbase/radio/src/thirdparty/"
["$_pkgbase/radio/src/thirdparty/"]="AccessDenied FreeRTOS-Kernel Segger_RTT"
["$_pkgbase/radio/src/thirdparty/FreeRTOS/portable/ThirdParty/"]="FreeRTOS-Kernel-Community-Supported-Ports FreeRTOS-Kernel-Partner-Supported-Ports"
["$_pkgbase/radio/src/thirdparty/libopenui/thirdparty/"]="lvgl stb"
)
for path in "${!submodules[@]}"; do
cd $path
git submodule init git submodule init
for module in ${submodules[$path]}; do git config submodule.AccessDenied.url $srcdir/AccessDenied
git config submodule.$module.url $srcdir/$module git config submodule.FreeRTOS-Kernel.url $srcdir/FreeRTOS-Kernel
done git config submodule.Segger_RTT.url $srcdir/Segger_RTT
git submodule update --init
cd "$_pkgbase/radio/src/thirdparty/FreeRTOS/portable/ThirdParty/"
git submodule init
git config submodule.FreeRTOS-Kernel-Community-Supported-Ports.url $srcdir/FreeRTOS-Kernel-Community-Supported-Ports
git config submodule.FreeRTOS-Kernel-Partner-Supported-Ports.url $srcdir/FreeRTOS-Kernel-Partner-Supported-Ports
git submodule update --init
cd "$_pkgbase/radio/src/thirdparty/libopenui/thirdparty/"
git submodule init
git config submodule.lvgl.url $srcdir/lvgl
git config submodule.stb.url $srcdir/stb
git submodule update --init git submodule update --init
done
} }
build() { build() {