99# keep_bootloader=y -- don't redownload the bootloader, only rebuild it
1010# keep_etc=y -- don't overwrite the /etc partition
1111#
12+ # reconfigure_kernel=y -- reconfigure kernel
13+ # reconfigure_rootfs=y -- reconfigure rootfs
14+ # reconfigure_boot=y -- reconfigure bootloader
15+ #
1216
1317SET_BAUDRATE=' -b 2000000'
1418
@@ -106,6 +110,14 @@ if [ ! -d build-buildroot-$BUILDROOT_CONFIG ] ; then
106110 buildroot/utils/config --file build-buildroot-$BUILDROOT_CONFIG /.config --set-str TOOLCHAIN_EXTERNAL_PREFIX ' $(ARCH)-esp32s3-linux-uclibcfdpic'
107111 buildroot/utils/config --file build-buildroot-$BUILDROOT_CONFIG /.config --set-str TOOLCHAIN_EXTERNAL_CUSTOM_PREFIX ' $(ARCH)-esp32s3-linux-uclibcfdpic'
108112fi
113+ if [ -n " $reconfigure_rootfs " ] ; then
114+ nice make -C buildroot O=` pwd` /build-buildroot-$BUILDROOT_CONFIG menuconfig
115+ nice make -C buildroot O=` pwd` /build-buildroot-$BUILDROOT_CONFIG savedefconfig
116+ fi
117+ if [ -n " $reconfigure_kernel " ] ; then
118+ nice make -C buildroot O=` pwd` /build-buildroot-$BUILDROOT_CONFIG linux-menuconfig
119+ nice make -C buildroot O=` pwd` /build-buildroot-$BUILDROOT_CONFIG linux-savedefconfig
120+ fi
109121nice make -C buildroot O=` pwd` /build-buildroot-$BUILDROOT_CONFIG
110122[ -f build-buildroot-$BUILDROOT_CONFIG /images/xipImage -a -f build-buildroot-$BUILDROOT_CONFIG /images/rootfs.cramfs -a -f build-buildroot-$BUILDROOT_CONFIG /images/etc.jffs2 ] || exit 1
111123
@@ -120,6 +132,10 @@ cd esp-idf
120132cd ../network_adapter
121133idf.py set-target esp32s3
122134cp $ESP_HOSTED_CONFIG sdkconfig || die " Could not apply IDF config $ESP_HOSTED_CONFIG "
135+ if [ -n " $reconfigure_boot " ] ; then
136+ idf.py menuconfig
137+ cp sdkconfig $ESP_HOSTED_CONFIG
138+ fi
123139idf.py build
124140read -p ' ready to flash... press enter'
125141while ! idf.py $SET_BAUDRATE flash ; do
0 commit comments