User Tools

Site Tools


xilinx_petalinux

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
xilinx_petalinux [2019/05/08 10:59]
rpjday [Earlier versions on Fedora 30]
xilinx_petalinux [2019/09/15 10:42]
rpjday [Overview]
Line 1: Line 1:
 ===== Overview ===== ===== Overview =====
  
-Installing/​using ​Petalinux ​-- installation on unsupported Fedora 30.+Directory structure of (relevant) installed ​Petalinux ​2019.1.
  
-===== Links ===== +  * settings.sh 
- +  * tools/ 
-  * [[https://www.xilinx.com/support/​download/​index.html/​content/​xilinx/​en/​downloadNav/​embedded-design-tools.html|Download Petalinux]] +    * common/petalinux
- +      ​* ​bin/ 
-===== Workarounds ===== +        * petalinux-boot 
- +        * petalinux-build 
-==== Fixing bash ==== +        petalinux-config 
- +        ​petalinux-create 
-Add this ''​sed''​ wrapper to get around a whitespace issue with newer bash: +        ​petalinux-package 
- +        ​* petalinux-upgrade 
-<​code>​ +        ​* petalinux-util 
-#!/bin/sh +      * utils
- +        * petalinux-component 
-# Remove newlines if called by the silly Xilinx PetaLinux 2018.1 installer +        * petalinux-detect-arch 
-if [ "​$2"​ = "s/^.*minimal-\(.*\)-toolchain.*/\1/" ] ; then +        * petalinux-edit-searchpath 
-        ​/bin/sed "​$@"​ | tr '​\n'​ ' ' +        * petalinux-env-check 
-else +        * petalinux-find-ipaddr 
-        ​/bin/sed "​$@"​ +        * petalinux-find-systool 
-fi +        * petalinux-gen-nfsroot 
-</code> +        * petalinux-initbram 
- +        * petalinux-install 
-==== Fixing tr ==== +        * petalinux-jtag-boot 
- +        * petalinux-kconfig-edit 
-If you see this when you source ''​settings.sh'':​ +        ​* ​petalinux-linuxsys-utils 
- +        * petalinux-package-boot 
-<​code>​ +        petalinux-package-bsp 
-INFO: Checking installed tools +        petalinux-package-image 
-tr: extra operand ‘k’ +        petalinux-package-prebuilt 
-Try '​tr ​--help' for more information. +        petalinux-package-sysroot 
-tr: extra operand ‘k’ +        petalinux-qemu-boot 
-Try '​tr ​--help' for more information. +        petalinux-simple-yaml-parser 
-tr: extra operand ‘k’ +        petalinux-tranwebt 
-Try '​tr ​--help' for more information. +        petalinux-yocto 
-... +    * xsct
-</​code>​ +      * bin
- +      * gnu/ 
-just move to a directory that does not contain any single-letter file or directory names. The problem is that the arguments to ''​tr''​ are not being quoted properly. +        * aarch32/
-===== Installation ===== +
- +
-==== Latest version ==== +
- +
-<​code>​ +
-$ ./petalinux-v2018.3-final-installer.run ~/​xilinx/​install/​petalinux_2018.3 +
-</​code>​ +
- +
-Installation dirs (WRT ${PETALINUX}):​ +
- +
-  ​components/ +
-    apps/ +
-      gpio-demo/ +
-      peekpoke/ +
-    misc/ +
-      config/ +
-      plnx-generated/ +
-      rootfs_config/​ +
-    * yocto+
-      * downloads+
-      * source/+
         * aarch64/         * aarch64/
-        * arm+        * armr5
-        * microblaze_full/ +        * microblaze
-        * microblaze_lite/​ +  * etc
- +    * template/project
-  * .../aarch64+      template-zynqMP
-    * buildtools/ +        config.project 
-    * conf+        * project-spec/
-    downloads/​ +
-    * layers/ +
-    * sstate-cache+
-    sysroots/ +
-    * workspace/​ +
- +
-==== Earlier versions on Fedora 30 ==== +
- +
-Version 2017.4: +
- +
-<​code>​ +
-ERROR: You are missing the following system tools required by PetaLinux:​ +
- +
- - xvfb-run +
- - ccache +
- - glib2-devel +
-</​code>​ +
- +
-Version 2018.2: +
- +
-<​code>​ +
-ERROR: You are missing the following system tools required by PetaLinux:​ +
- +
- - xvfb-run +
-</​code>​ +
- +
-Fix: +
- +
-<​code>​ +
-$ sudo dnf install xorg-x11-server-Xvfb +
-</​code>​ +
-===== Building a project ​===== +
- +
-==== petalinux-create ==== +
- +
-<​code>​ +
-Usage: +
-  petalinux-create [options] <​-t|--type <​TYPE>​ <​-n|--name <​COMPONENT_NAME>​ +
- +
-Required: +
-  -t, --type <​TYPE> ​                    ​Available type: +
-                                          ​* project ​: PetaLinux project +
-                                          * apps    : Linux user application +
-                                          * modules : Linux user module +
-  ​-n, --name <​COMPONENT_NAME> ​          ​specify a name for the component or +
-                                        project. It is OPTIONAL to create a +
-                                        PROJECT. If you specify source BSP when +
-                                        you create a project, you are not +
-                                        required to specify the name. +
-Options: +
-  -p, --project <​PROJECT> ​              ​specify full path to a PetaLinux project +
-                                        this option is NOT USED for PROJECT CREATION. +
-                                        default is the working project. +
-  --force ​                              force overwriting an existing component +
-                                        directory. +
-  -h, --help ​                           show function usage +
-  --enable ​                             this option applies to all types except +
-                                        project. +
-                                        enable the created component +
- +
-Options for project: +
-  --template <​TEMPLATE> ​                ​zynqMP|zynq|microblaze +
-                                        user needs specify which template to use. +
-  -s|--source <​SOURCE> ​                 specify a PetaLinux BSP as a project +
-                                        source. +
-</​code>​ +
- +
-==== Building from BSP ==== +
- +
-<​code>​ +
-$ petalinux-create \ +
-  --type project \ +
-  --source ~/​xilinx/​petalinux/​projects/​zed/​avnet-digilent-zedboard-v2018.3-final.bsp \ +
-  --name zed_from_bsp +
- +
-</​code>​ +
- +
-===== Building with newer version ===== +
- +
-<​code>​ +
-$ petalinux-build +
-WARNING: Your PetaLinux project was last modified by PetaLinux SDK version "​2017.4",​ +
-WARNING: however, you are using PetaLinux SDK version "​2018.3"​. +
-Please input "​y"​ to continue. Otherwise it will exit![n] +
-</code>+
  
 +===== zynqMP project-spec/​ =====
  
 +  * attributes
 +  * configs/
 +    * config
 +    * rootfs_config
 +  * hw-description/​
 +    * metadata
 +  * meta-user/
 +    * recipes-bsp/​
 +      * device-tree/​
 +        * files/
 +          * multi-arch/
 +            * zynqmp-qemu-multiarch-arm.dts
 +            * zynqmp-qemu-multiarch-pmu.dts
 +          * zynqmp-qemu-arm.dts
 +      * u-boot/
 +        * files/
 +          * platform-top.h