|
@@ -75,6 +75,7 @@ DST_UBOOT_BOARD_PATH=$SDK_DIR/u-boot/board/arkmicro/$DST_BOARD_TYPE
|
|
cp -rf ${SDK_DIR}/u-boot/configs/${SRC_UBOOT_CONFIG_FILE} ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
cp -rf ${SDK_DIR}/u-boot/configs/${SRC_UBOOT_CONFIG_FILE} ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
sed -i s/CONFIG_TARGET_$SRC_UBOOT_TARGET/CONFIG_TARGET_$DST_UBOOT_TARGET/g ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
sed -i s/CONFIG_TARGET_$SRC_UBOOT_TARGET/CONFIG_TARGET_$DST_UBOOT_TARGET/g ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
sed -i s/$SRC_DTB_FILE_NAME/$DST_DTB_FILE_NAME/g ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
sed -i s/$SRC_DTB_FILE_NAME/$DST_DTB_FILE_NAME/g ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
|
|
+sed -i s/$SRC_BOARD_TYPE/$DST_BOARD_TYPE/g ${SDK_DIR}/u-boot/configs/${DST_BOARD_TYPE}_defconfig
|
|
|
|
|
|
# copy dts file and add in Makefile
|
|
# copy dts file and add in Makefile
|
|
UBOOT_DTS_PATH=${SDK_DIR}/u-boot/arch/arm/dts
|
|
UBOOT_DTS_PATH=${SDK_DIR}/u-boot/arch/arm/dts
|
|
@@ -118,6 +119,10 @@ mkdir -p $DST_UBOOT_BOARD_PATH
|
|
cp -rf $SRC_UBOOT_BOARD_PATH/* $DST_UBOOT_BOARD_PATH/
|
|
cp -rf $SRC_UBOOT_BOARD_PATH/* $DST_UBOOT_BOARD_PATH/
|
|
echo -e "if TARGET_$DST_UBOOT_TARGET\n\nconfig SYS_BOARD\n\tdefault \"$DST_BOARD_TYPE\"\n\nconfig SYS_VENDOR\n\tdefault \"arkmicro\"\n\n\
|
|
echo -e "if TARGET_$DST_UBOOT_TARGET\n\nconfig SYS_BOARD\n\tdefault \"$DST_BOARD_TYPE\"\n\nconfig SYS_VENDOR\n\tdefault \"arkmicro\"\n\n\
|
|
config SYS_CONFIG_NAME\n\tdefault \"$DST_BOARD_TYPE\"\n\nendif" > $DST_UBOOT_BOARD_PATH/Kconfig
|
|
config SYS_CONFIG_NAME\n\tdefault \"$DST_BOARD_TYPE\"\n\nendif" > $DST_UBOOT_BOARD_PATH/Kconfig
|
|
|
|
+if [ -f ${DST_UBOOT_BOARD_PATH}/${SRC_BOARD_TYPE}.c ];then
|
|
|
|
+ mv ${DST_UBOOT_BOARD_PATH}/${SRC_BOARD_TYPE}.c ${DST_UBOOT_BOARD_PATH}/${DST_BOARD_TYPE}.c
|
|
|
|
+ sed -i s/$SRC_BOARD_TYPE/$DST_BOARD_TYPE/g $DST_UBOOT_BOARD_PATH/Makefile
|
|
|
|
+fi
|
|
|
|
|
|
# add configs header file
|
|
# add configs header file
|
|
SRC_UBOOT_CONFIG_HEADER_FILE=$(sed -n '/SYS_CONFIG_NAME/{n;p;}' $SRC_UBOOT_BOARD_PATH/Kconfig | awk '{print $2}')
|
|
SRC_UBOOT_CONFIG_HEADER_FILE=$(sed -n '/SYS_CONFIG_NAME/{n;p;}' $SRC_UBOOT_BOARD_PATH/Kconfig | awk '{print $2}')
|