buildroot 中的其他分区
Additional partitions in buildroot
我想知道是否可以在分区 table 中添加更多分区,以及如何添加。
我已经测试过更改 genimage.cfg
但似乎 support/scripts/genimage.sh
没有创建它。
提前致谢。
使用 genimage.cfg
脚本是正确的方法。
如果还是不行,可能是你修改了错误的配置文件; genimage
通常由指定为的脚本调用
但是,请确保修改正确的配置文件,BR2_ROOTFS_POST_IMAGE_SCRIPT
选项中定义的脚本使用的配置文件,在 menuconfig
中的 System configuration-> Custom scripts to run after creating filesystem images
下。
例如,我修改了我的(特别是 boards/raspberrypi3-64/genimage-raspberrypi3-64.cfg
以容纳额外的 ext4 分区。
image boot.vfat {
vfat {
files = {
"bcm2710-rpi-3-b.dtb",
"bcm2710-rpi-3-b-plus.dtb",
"bcm2837-rpi-3-b.dtb",
"rpi-firmware/bootcode.bin",
"rpi-firmware/cmdline.txt",
"rpi-firmware/config.txt",
"rpi-firmware/fixup.dat",
"rpi-firmware/start.elf",
"rpi-firmware/overlays",
"Image"
}
}
size = 32M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
partition log {
partition-type = 0x83
image = "log.ext4"
}
}
我想知道是否可以在分区 table 中添加更多分区,以及如何添加。
我已经测试过更改 genimage.cfg
但似乎 support/scripts/genimage.sh
没有创建它。
提前致谢。
使用 genimage.cfg
脚本是正确的方法。
如果还是不行,可能是你修改了错误的配置文件; genimage
通常由指定为的脚本调用
但是,请确保修改正确的配置文件,BR2_ROOTFS_POST_IMAGE_SCRIPT
选项中定义的脚本使用的配置文件,在 menuconfig
中的 System configuration-> Custom scripts to run after creating filesystem images
下。
例如,我修改了我的(特别是 boards/raspberrypi3-64/genimage-raspberrypi3-64.cfg
以容纳额外的 ext4 分区。
image boot.vfat {
vfat {
files = {
"bcm2710-rpi-3-b.dtb",
"bcm2710-rpi-3-b-plus.dtb",
"bcm2837-rpi-3-b.dtb",
"rpi-firmware/bootcode.bin",
"rpi-firmware/cmdline.txt",
"rpi-firmware/config.txt",
"rpi-firmware/fixup.dat",
"rpi-firmware/start.elf",
"rpi-firmware/overlays",
"Image"
}
}
size = 32M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
partition log {
partition-type = 0x83
image = "log.ext4"
}
}