Xilinx提供方便建構linux的工具petalinux,優點是方便好用但缺點就是慢,對於我只需會工具的人而言,仍然是高效的開發工具。
查看各個功能使用help 指令
petalinux-create --help
petalinux-config –help
petalinux-build –help
petalinux-package –help
創建開發目錄<PROJECT>(以zynq作為範例)petalinux-create -t project --template zynq -n <PROJECT>
第一次配置需先導入hdf ,一定要在開發目錄下配置,不然會有錯誤。petalinux-config --get-hw-description <hdf path>
第二次配置功能就不用加路徑,除更新hdf外。petalinux-config
配置u-boot petalinux-config -c u-boot
配置kernelpetalinux-config -c kernel
配置根文件系統rootfspetalinux-config -c rootfs
可以編譯全部petalinux工程petalinux-build
各別編譯petalinux-build -c u-boot
petalinux-build -c kernel
petalinux-build -c rootfs
製作BOOT.BIN文件petalinux-package --boot --fsbl --fpga --u-boot --force