initdc / rootfs-tools

build workflow for rootfs images
Mozilla Public License 2.0
15 stars 2 forks source link

Documentation for building Ubuntu for VisionFive 2 #3

Open caizixian opened 1 year ago

caizixian commented 1 year ago

Thanks for the Ubuntu image. I successfully got it working with my VisionFive 2 board. I'm just wondering whether you can provide instructions on how to build a new image. I'd like to build new images when updated upstream SDKs are released, such as https://github.com/starfive-tech/VisionFive2/releases/tag/VF2_v2.8.0

initdc commented 1 year ago
  1. get buildroot v2.8.0 sdcard.img, ubuntu cloud image root.tgz, img-gpu-powervr-bin-1.17.6210866.tar.gz
  2. sudo decompress ubuntu to folder ub-22, don't make change on it for re-use
  3. mountCombinedImage, sudo backup firmware module fstab, unmountCombinedImage
  4. fdisk -> get disk layout
  5. dd resize sdcard.img
  6. change rootfs par size of disk layout file, then load
  7. mountCombinedImage, format rootfs par
  8. sudo cp -a ub-22/* rootfs
  9. copy_kernel /full-path/rootfs-tools/backup rootfs
  10. decompress gpu driver and copy to rootfs if you can handle it
  11. copy vendor vf2 config.sh, change as you need
  12. simple job don't need mountDev, just sudo chroot rootfs and run config.sh. if you need change systemd daemon service or install software, you need do so
  13. unmountCombinedImage
caizixian commented 1 year ago

Thanks, I think understand the rough workflow now. I will give it a try.