petalinux 使用指南:
新建petalinux工程,工程名为ax7z100, 模板类型为zynq-7000:
petalinux-create -t project -n ax7z100 --template zynq
配置petalinuxg工程,有以下命令
1. petalinux-config --get-hw-description <HDF/XSA文件的路径>
通过vivado工程导出的hdf或xsa(vivado2019.2的格式)硬件信息,
初始化petalinux工程,如果hdf或xsa路径没有指定则默认在当前路径查找
2. petalinux-config
开始系统级别的配置,如boot device,hostname等
3. petalinux-config -c kernel --defconfig xilinx_zynq_defconfig
根据指定的配置文件初始化kernel配置
4. petalinux-config -c rootfs 配置根文件系统
5. petalinux-config -c u-boot 配置uboot
6. petalinux-config -c rootfs --oldconfig/--silentconfig
恢复之前的配置
7. petalinux-config -c bootloader
生成fsbl源码
编译petalinux工程:
petalinux-build -c bootloader|kernel|u-boot|rootfs|device-tree
petalinux-build -x build|clean|cleanall|distclean|install|package
样例:
petalinux-build //编译工程的全部组件,包括kernel,u-boot,rootfs
petalinux-build -c kernel -f //从最后一个成功编译的输出任务中强制编译kernel
petalinux-build -x distclean
petalinux-build -c u-boot -x cleansstate
petalinux-build -x mrproper //使petalinux工程回到初始化状态
petalinux-build -x package //从当前petalinux -c all 工程创建FIT image(image.ub)
本内容试读结束,登录后可阅读更多
下载后可阅读完整内容,剩余1页未读,立即下载