[yocto] Python-installation on target (qemuppc) image ....

Gary Thomas gary at mlbassoc.com
Thu Oct 4 05:38:47 PDT 2012


On 2012-10-04 06:27, Jonas Jonsson L wrote:
> Hi,
> I'm trying to get a working python on a 'core-image-minimal' type of image but with no luck.  Loads of stuff from the standard python library aren't installed on the target
> (qemuppc), as an example I can't run 'python-config' since the 'distutils'-module isn't available.  I need the 'shutil' module on my image but I can't figure out how to achive
> that.  Python seems to work on the target but it seems to lack lots of standard functionality.
> The shutil.py & shutil.pyo exists in .../build/tmp/work/ppc603e-poky-linux/python-2.7.3-r0.2/package/usr/lib/python2.7 folder but it doesn't exist on the target image...
> Also, in ..../deploy-rpms/ppc603e/python-shell-2.7.3-r0.2.ppc603e.rpm, the shutil-files exist ...
> Somehow, it seems as if this rpm isn't installed on my target-image, what controls that?
> Examining the log.do_package-file shows ~5700 lines of "error: Couldn't exec ..../sysroot//*x86_64-linux*//usr/lib/rpm/pythoneggs.py: No such file or directory" (shouldn't it be
> qemupcc??) from function package_do_filedeps.
> Examining the log.do_populate_sysroot-file shows "WARNING: The recipe is trying to install files into a shared area when those files already exist. Those files are: pyconfig.h,
> libpython2.7.so, libpython2.7.so.1.0 and Makefile" ....

Python packages are split up into functionality and you'll need
to install the pieces that you need.  Remember that these systems
are presumed to be [somewhat] small, embedded devices and there's
no sense to install what you will never use...

For example, you need to install 'python-distutils' to get the distutils module.

-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------



More information about the yocto mailing list