UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Observer k4rm4n
Observer
10,031 Views
Registered: ‎08-22-2016

Add python (or any rpm) on Petalinux

Jump to solution

Hello,

 

Thanks all for read me.

 

I need to add Python in my Petalinux image.

 

1- In petalinux 2016.1 i can see  python rpm packages (for example python-core-2.7.9-r1.cortexa9hf_vfp_neon.rpm) in the folder:

 

/opt/pkg/petalinux-v2016.1-final/components/packages-repo/plnx-repo/rpm/cortexa9hf_vfp_neon

 

If i try to add this packages:

 

petalinux-config -c rootfs --> Root file system package --> I DONT SEE ANY python option.

 

 

2 - Additionally I tried to use yocto with meta-petalinux. I was able to build the python packages with the rpm result. In this point i obtain the same rpms as first point (for example python-core-2.7.9-r1.cortexa9hf_vfp_neon.rpm) but I dont know how to add this packages in my petalinux image.

 

I tried bymyself find information about this, but nothing clear and I am not an expert. Any help, hint or solution will be very welcome.

 

Regards.

 

 

 

 

 

 

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Explorer
Explorer
9,142 Views
Registered: ‎11-09-2015

Re: Add python (or any rpm) on Petalinux

Jump to solution

hi, petalinux16.4 contain python,you can use petaconfig -c rootfs to select it.

Location:  
 -> Filesystem Packages
     -> devel 
         -> python 
              -> python

tips: your can use / to search,and then type “python”and enter to search.

then press 1 to jump to the configuration.

 

BRs,

9 Replies
Scholar austin
Scholar
10,011 Views
Registered: ‎02-27-2008

Re: Add python (or any rpm) on Petalinux

Jump to solution

k,

 

Have you read through the threads here on the subject?  Search for zynq python

 

 

Austin Lesea
Principal Engineer
Xilinx San Jose
Xilinx Employee
Xilinx Employee
10,003 Views
Registered: ‎08-01-2008

Re: Add python (or any rpm) on Petalinux

Jump to solution
check this related post
https://forums.xilinx.com/t5/Embedded-Linux/How-to-add-applications-to-petalinux/td-p/490012
Thanks and Regards
Balkrishan
--------------------------------------------------------------------------------------------
Please mark the post as an answer "Accept as solution" in case it helped resolve your query.
Give kudos in case a post in case it guided to the solution.
Observer k4rm4n
Observer
9,978 Views
Registered: ‎08-22-2016

Re: Add python (or any rpm) on Petalinux

Jump to solution

Thanks for your answers,

 

All post i reviewed doesnt show clear information. In Petalinux manual and yocto wiki also i cannot see information about how to load packages in petalinux image.

 

Could i merge the rootfs from yocto with the packages i want with the petalinux one?

0 Kudos
Observer k4rm4n
Observer
9,966 Views
Registered: ‎08-22-2016

Re: Add python (or any rpm) on Petalinux

Jump to solution

Hello,

 

I added python with petalinux 2016.1 (originally i had 2015.4 and I didnt source the 2016.1 seetings.sh).

 

petalinux-config -c rootfs

 

Even i added from petalinux, is there any way to add other custom packages compiled with yocto?

 

0 Kudos
Xilinx Employee
Xilinx Employee
9,929 Views
Registered: ‎07-01-2010

Re: Add python (or any rpm) on Petalinux

Jump to solution

@k4rm4n

 

I think you can add custom package to petalinux.

 

Refer to the below answer record which has the details you are looking for.

 

How to add package to Petalinux - http://www.xilinx.com/support/answers/67160.html

How do I add a script to my PetaLinux root file system that runs at startup?- http://www.xilinx.com/support/answers/55998.html

 

 

Regards,
Achutha

 

---------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------
Scholar austin
Scholar
9,447 Views
Registered: ‎02-27-2008

Re: Add python (or any rpm) on Petalinux

Jump to solution

see Steve blog:  PYNQ

Austin Lesea
Principal Engineer
Xilinx San Jose
Participant rankeney
Participant
9,438 Views
Registered: ‎11-26-2014

Re: Add python (or any rpm) on Petalinux

Jump to solution

FWIW, I have cross-compiled Python 2.7.3 for the Zynq platform. You can find it at:

https://www.dropbox.com/s/r5zh3qpl647rf9m/Python-2.7.3.tar.gz?dl=0

Hopefully you have an ext4 partition on your SD card. You can create a /usr/local directory there and extract the archive into that folder.

 

0 Kudos
Explorer
Explorer
7,508 Views
Registered: ‎10-14-2015

Re: Add python (or any rpm) on Petalinux

Jump to solution

I am in the same situation.

 

I have generated apparmor rpm following the mentioned guides, I have copy the package in /opt/Xilinx/petalinux-2016.2/components/package-repo/rpm/cortexa9hf_vfp_neon folder, but I can't see it in menuconfig for rootfs.

 

Clearly some extra steps are missing in the guide

0 Kudos
Highlighted
Explorer
Explorer
9,143 Views
Registered: ‎11-09-2015

Re: Add python (or any rpm) on Petalinux

Jump to solution

hi, petalinux16.4 contain python,you can use petaconfig -c rootfs to select it.

Location:  
 -> Filesystem Packages
     -> devel 
         -> python 
              -> python

tips: your can use / to search,and then type “python”and enter to search.

then press 1 to jump to the configuration.

 

BRs,