Summary: | dev-embedded/bitbake-1.17.0:ImportError: No module named pysh | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Toralf Förster <toralf> |
Component: | Current packages | Assignee: | Embedded Gentoo Team <embedded> |
Status: | RESOLVED OBSOLETE | ||
Severity: | normal | CC: | chewi, fordfrog, hendrik, henning, mgorny, newchief, pr.gentoo-acct |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
emerge log
package list |
Description
Toralf Förster
![]() Created attachment 404356 [details]
package list
Comment on attachment 404356 [details]
package list
What is that? I can't get it.
(In reply to Mikle Kolyada from comment #2) > Comment on attachment 404356 [details] > package list > > What is that? I can't get it. The list of all currently installed packages of that chroot image. And I can download it fine - so why do you mark it as obsolete ? I had the same "No module named pysh" when I tried to emerge this package. according to their mailinglist [1], setup.py is not to be used. that file has been removed from their git repo as well, which makes bitbake-9999 unusable. this ebuild should (probably) simply copy the files and use them directly. [1] http://lists.openembedded.org/pipermail/bitbake-devel/2015-May/005703.html $ cd /local; tar -xzvf /usr/portage/distfiles/bitbake-1.17.0.tar.gz $ export PATH="${PATH}:/local/bitbake-1.17.0/bin" $ bitbake --help Usage: bitbake [options] [recipename/target ...] Executes the specified task (default is 'build') for a given set of target recipes (.bb files). It is assumed there is a conf/bblayers.conf available in cwd or in BBPATH which will provide the layer, BBFILES and other configuration information. Options: --version show program's version number and exit -h, --help show this help message and exit -b BUILDFILE, --buildfile=BUILDFILE [..] $ bitbake wrlinux-image-glibc-small Parsing recipes: 100% |###############################################################################################################################| Time: 00:03:36 Parsing of 2236 .bb files complete (0 cached, 2236 parsed). 2805 targets, 104 skipped, 5 masked, 0 errors. NOTE: Resolving any missing task queue dependencies [..] (In reply to Petre Rodan from comment #4) ... > according to their mailinglist [1], setup.py is not to be used. that file > has been removed from their git repo as well, which makes bitbake-9999 > unusable. > > this ebuild should (probably) simply copy the files and use them directly. > > [1] > http://lists.openembedded.org/pipermail/bitbake-devel/2015-May/005703.html > > $ cd /local; tar -xzvf /usr/portage/distfiles/bitbake-1.17.0.tar.gz > $ export PATH="${PATH}:/local/bitbake-1.17.0/bin" > $ bitbake --help ... I hit the same issuse. Is there a patch for the ebuild? At http://www.openembedded.org/wiki/OEandYourDistro#Gentoo_instructions it is stated, that before installing bitbake psyco, pysqlite, chrpath, fakeroot etc should be installed. And it is noted that Psyco, the Python JIT compiler, requires python-2.6.6 and works on 32-bit x86 platforms only. Is there not any way to install bitbake on a current system? The same here on newly installed gentoo. Strangely, on one of my older x86_64 gentoo systems I got this version of bitbake installed: [ebuild R ] dev-embedded/bitbake-1.17.0::gentoo USE="-doc" PYTHON_TARGETS="python2_7" 0 KiB FYI, pysh IS included in the bitbake sources (you can see it in the output: /var/tmp/portage/dev-embedded/bitbake-1.17.0/work/bitbake-1.17.0-python2_7/lib/bb/pysh) It's just a matter of fixing looking in the lib/bb directory while building (a quick workaround would be to set the PYTHONPATH to point to it after it fails the first time). Here the same problem. Seems that is discouraged to install bitbake system wide: http://git.openembedded.org/bitbake/commit/?id=e446281fbdd13cdfd2e39af0f48035829e2133ba Same here. I met this issue too. I think it maybe is the ebuild issue. 1. The root cause maybe is python couldn't locate the local pysh package exactly. $ cat bitbake-1.17.0/setup.py #!/usr/bin/env python # ex:ts=4:sw=4:sts=4:et # -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- # # Copyright (C) 2003 Chris Larson # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License along # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. import os, sys sys.path.append(os.path.join(os.path.dirname(__file__), "lib")) from bb import __version__ from glob import glob from distutils.command.clean import clean from distutils.command.build import build from distutils.core import setup doctype = "html" class Clean(clean): def run(self): clean.run(self) ... ... When I appended a "sys.path.append(os.path.join(os.path.dirname(__file__), "lib/bb"))" below "sys.path.append(os.path.join(os.path.dirname(__file__), "lib"))", this issue will be fixed. 2. So, maybe the following modification is workable. $ cat /usr/portage/dev-embedded/bitbake/bitbake-1.17.0.ebuild # Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI="5" PYTHON_COMPAT=( python2_7 ) PYTHON_REQ_USE="sqlite" inherit distutils-r1 vcs-snapshot if [[ ${PV} == *9999 ]]; then EGIT_REPO_URI="git://git.openembedded.org/bitbake.git" inherit git-r3 else SRC_URI="https://github.com/openembedded/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" KEYWORDS="amd64 ppc x86" fi DESCRIPTION="package management tool for OpenEmbedded" HOMEPAGE="http://git.openembedded.org/bitbake/" LICENSE="GPL-2" SLOT="0" IUSE="doc" RDEPEND=" dev-python/ply[${PYTHON_USEDEP}] dev-python/progressbar[${PYTHON_USEDEP}]" DEPEND="doc? ( dev-libs/libxslt )" src_prepare() { if ! use doc ; then sed -i -e 's:doctype = "html":doctype = "none":' \ -e 's:("share/doc/bitbake-%s/manual.*))::' setup.py || die echo "none:" >> doc/manual/Makefile || die else sed -i -e "s:\(share/doc/bitbake-%s.* %\) __version__:\1 \"${PV}\":" setup.py || die sed -i -e '/sys.path.append/asys.path.append(os.path.join(os.path.dirname(__file__), "lib/bb"))' setup.py # !!! I AM HERE !!! fi } At last, I don't know if this modification is good, but I am sure it is workable for me. AND, I DON'T KNOW how to commit this patch. Who can help me, check or review this modification? The package is being removed wrt bug #540360. |