Merge branch 'main' into features/prebuilt-rootfs

This commit is contained in:
Samuel Lee
2024-07-14 14:02:38 +09:00
committed by GitHub
73 changed files with 6129 additions and 2172 deletions

View File

@@ -40,6 +40,7 @@ DTS_CONFIG=${SDK_CONFIG_DIR}/dts_config
KERNEL_DEFCONFIG=${SDK_CONFIG_DIR}/kernel_defconfig
BUILDROOT_DEFCONFIG=${SDK_CONFIG_DIR}/buildroot_defconfig
PREBUILT_ROOTFS_PATH=${SDK_ROOT_DIR}/prebuilt_rootfs.tar.gz
UBUNTU_DIR=${SDK_SYSDRV_DIR}/tools/board/ubuntu
if [ $(getconf _NPROCESSORS_ONLN) -eq 1 ]; then
export RK_JOBS=1
@@ -560,8 +561,6 @@ function build_check() {
}
function build_app() {
check_config RK_APP_TYPE || return 0
if [ "$RK_ENABLE_WIFI" = "y" ]; then
echo "Set Wifi SSID and PASSWD"
check_config LF_WIFI_PSK LF_WIFI_SSID || return 0
@@ -580,6 +579,8 @@ EOF
mv $WIFI_NEW_CONF $WIFI_CONF
fi
check_config RK_APP_TYPE || return 0
echo "============Start building app============"
echo "TARGET_APP_CONFIG=$RK_APP_DEFCONFIG $RK_APP_DEFCONFIG_FRAGMENT $RK_APP_TYPE"
echo "========================================="
@@ -1093,6 +1094,9 @@ function build_clean() {
make distclean -C ${SDK_APP_DIR}
rm -rf ${RK_PROJECT_OUTPUT_IMAGE} ${RK_PROJECT_OUTPUT}
rm -rf ${DTS_CONFIG} ${KERNEL_DEFCONFIG} ${BUILDROOT_DEFCONFIG}
rm -rf ${SDK_ROOT_DIR}/output ${SDK_ROOT_DIR}/config
rm -rf ${SDK_ROOT_DIR}/sysdrv/source/kernel/out
rm -rf ${BOARD_CONFIG}
;;
*)
msg_warn "clean [$1] not support, ignore"
@@ -1278,6 +1282,10 @@ echo SDK Version: ${GLOBAL_SDK_VERSION}
EOF
chmod a+x $RK_PROJECT_PACKAGE_ROOTFS_DIR/bin/sdkinfo
if [ "$RK_BOOT_MEDIUM" == "emmc" ] && [ "$LF_TARGET_ROOTFS" == "ubuntu" ]; then
cp $WIFI_CONF $RK_PROJECT_PACKAGE_ROOTFS_DIR/etc
fi
__COPY_FILES $RK_PROJECT_PATH_APP/root $RK_PROJECT_PACKAGE_ROOTFS_DIR
__COPY_FILES $RK_PROJECT_PATH_MEDIA/root $RK_PROJECT_PACKAGE_ROOTFS_DIR
__COPY_FILES $SDK_ROOT_DIR/external $RK_PROJECT_PACKAGE_ROOTFS_DIR
@@ -1871,6 +1879,9 @@ __GET_BOOTARGS_FROM_BOARD_CFG() {
__LINK_DEFCONFIG_FROM_BOARD_CFG() {
mkdir -p ${SDK_CONFIG_DIR}
if [[ "$LF_TARGET_ROOTFS" == "ubuntu" ]]; then
sudo chmod a+rw $SDK_CONFIG_DIR
fi
if [ -n "$RK_KERNEL_DTS" ]; then
rm -f $DTS_CONFIG
@@ -2190,6 +2201,7 @@ function build_save() {
STUB_PATH="$(echo $STUB_PATH | tr '[:lower:]' '[:upper:]')"
export STUB_PATH=$SDK_ROOT_DIR/$STUB_PATH
export STUB_PATCH_PATH=$STUB_PATH/PATCHES
export STUB_PARENT_PATH="$SDK_ROOT_DIR"/IMAGE
STUB_DEBUG_FILES_PATH="$STUB_PATH/DEBUG_FILES"
mkdir -p $STUB_PATH $STUB_PATCH_PATH
@@ -2213,6 +2225,11 @@ function build_save() {
echo "BUILD-ID: $(hostname):$(whoami)" >>$STUB_PATH/build_info.txt
build_info >>$STUB_PATH/build_info.txt
echo "save to $STUB_PATH"
if [[ "$LF_TARGET_ROOTFS" == "ubuntu" ]]; then
sudo chmod a+rw $STUB_PARENT_PATH
fi
finish_build
}
@@ -2303,7 +2320,13 @@ if [[ "$LF_TARGET_ROOTFS" = "ubuntu" ]]; then
exit 0
fi
fi
git submodule update --init --recursive
if [ -d "$UBUNTU_DIR" ] && [ -f ${UBUNTU_DIR}/luckfox-ubuntu-22.04.3.tar.gz ]; then
msg_info "${UBUNTU_DIR} is not empty, skipping submodule update!"
else
msg_info "${UBUNTU_DIR} is empty or does not exist, updateing submodule!"
git submodule update --init --recursive
fi
fi
if echo $@ | grep -wqE "help|-h"; then
@@ -2382,4 +2405,3 @@ while [ $# -ne 0 ]; do
done
eval "${option:-build_allsave}"

View File

@@ -8,13 +8,13 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1106
# export RK_APP_TYPE=RKIPC_RV1106
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="66M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1106g-luckfox-pico-ultra-w.dts
export RK_KERNEL_DTS=rv1106g-luckfox-pico-ultra.dts
#################################################
# BOOT_MEDIUM

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1106
# export RK_APP_TYPE=RKIPC_RV1106
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="66M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1106g-luckfox-pico-ultra-w.dts

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1103
# export RK_APP_TYPE=RKIPC_RV1103
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="24M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1103g-luckfox-pico.dts

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1103
# export RK_APP_TYPE=RKIPC_RV1103
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="24M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1103g-luckfox-pico-mini-a.dts

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1103
# export RK_APP_TYPE=RKIPC_RV1103
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="24M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1103g-luckfox-pico-mini-b.dts

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1103
# export RK_APP_TYPE=RKIPC_RV1103
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="24M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1103g-luckfox-pico-plus.dts

View File

@@ -8,10 +8,10 @@
export RK_CHIP=rv1106
# app config
export RK_APP_TYPE=RKIPC_RV1106
# export RK_APP_TYPE=RKIPC_RV1106
# Config CMA size in environment
export RK_BOOTARGS_CMA_SIZE="66M"
export RK_BOOTARGS_CMA_SIZE="1M"
# Kernel dts
export RK_KERNEL_DTS=rv1106g-luckfox-pico-pro-max.dts