[yocto] YoctoProject: problem bitbake core-image-minimal

Trevor Woerner twoerner at gmail.com
Wed Oct 26 05:38:01 PDT 2016


Hi Luca,

Thank you for providing a more complete problem report. There are two
problems you will need to fix in order for your build to succeed:

1) Don't run the build as the root user. Editing sanity.conf to get
rid of the build failure is not the solution to avoid the build
failing because it is being invoked as the root user. The correct
solution is to create a non-privileged user, login as that user, and
run the build as that user.

2) Fix the networking in your VM. It doesn't look like git works from
within your VM. Does the "git clone" command work on your host? In any
case, performing a build will require your build VM to be able to
access the internet in order to perform many downloads. A normal build
will invoke git, subversion, and other repository fetches as well as
downloading many tarballs. So without networking working properly a
build is not possible.

Best regards,
    Trevor


On Wed, Oct 26, 2016 at 3:23 AM, Luca Boscariol DEC
<lboscariol at decelettronica.com> wrote:
> Hi Trevor.
>
> I'm working in VMware Virtual Machine.
> I have installed Open Suse Desktop 12 (SLED 12) (x86_64)
> Linux version 3.12.28-4-default
>
> I'm following:
> http://www.yoctoproject.org/docs/2.1/mega-manual/mega-manual.html
>
> I have installed:
> python-2.7.7-2.12.x86_64
> git-2.10.1-318.1.x86_64
> tar-1.27.1-2.22.x86_64
> gcc        4.8
> gcc-c++        4.8
> make         4.0
> wget         1.14
> python-xml     2.7
> diffstat     1.61
> makeinfo    4.13a
> python-curses    2.7.7
> patch        2.7.1
> socat        1.7.2.4
> libSDL        1.2.15
>
> First I have tried to used command:
>     git clone -b krogoth git://git.yoctoproject.org/poky.git
>
> but connection refused.
> Output is following:
> ----------------------------------------------------------------------------
>     Cloning into 'poky...
>     fatal: unable to connect to git.yoctoproject.org:
>     git.yoctoproject.org[0:140.211.169.56]: errno=Connection refused
> ----------------------------------------------------------------------------
> How can I use clone repository?
>
>
>
> Next, I have downloaded from
> http://downloads.yoctoproject.org/releases/yocto/yocto-2.1.1/poky-krogoth-15.0.1.tar.bz2
>
>
> Then
>     tar -xvf poky-krogoth-15.0.1.tar.bz2
>
> in /opt directory
>
>
> I have modified file build/conf/local.conf in following mode:
>     #MACHINE ??= "qemux86"
>     MACHINE ??= "qemuarm"
>
> I run script:
>     source oe-init-build-env
>
> Output is:
> ----------------------------------------------------------------------------
> #### Shell enviroment set up for builds. ###You can now run 'bitbake
> <target>'
>
> Common targets are:
>     core-image-minimal
>     core-image-sato
>     meta-toolchian
>     meta-ide-support
>
> You can also run generated qemu images with a command like 'runqemu qemux86
> ----------------------------------------------------------------------------
>
>
> To conserve disk space, I have added in build/conf/local.conf
>     INHERIT += "rm_work"
>
> When i run a script:
>     bitbake core-image-minimal
> I have 1 error.
>
> Output is:
> ----------------------------------------------------------------------------
> ERROR: OE-core's config sanity checker detected a potential
> misconfiguration.
> Either fix the cause of this error or at your own risk disable the checker
> (see sanity.conf).
> Following is the list of potential problems / advisories:
>
> Do not use Bitbake as root
> ----------------------------------------------------------------------------
>
>
>
> Then, I have modified file /meta/conf/sanity.conf in following mode:
>
>     #INHERIT += "sanity"
>     #INHERIT += "rm_work"
>
>
> I change directory:
>     /build
>
>
> I run:
>     bitbake core-image-minimal
>
> Output is:
> ----------------------------------------------------------------------------
> Parsing recipes: 100% |
>
> #############################################################################################################################################################################################################################################
>
> ########################################| Time: 00:00:46
> Parsing of 871 .bb files complete (0 cached, 871 parsed). 1301 targets, 66
> skipped, 0 masked, 0 errors.
> NOTE: Resolving any missing task queue dependencies
>
> Build Configuration:
> BB_VERSION        = "1.30.0"
> BUILD_SYS         = "x86_64-linux"
> NATIVELSBSTRING   = "SUSELINUX-12"
> TARGET_SYS        = "arm-poky-linux-gnueabi"
> MACHINE           = "qemuarm"
> DISTRO            = "poky"
> DISTRO_VERSION    = "2.1.1"
> TUNE_FEATURES     = "arm armv5 thumb dsp"
> TARGET_FPU        = "soft"
> meta
> meta-poky
> meta-yocto-bsp    = "<unknown>:<unknown>"
>
> NOTE: Fetching uninative binary shim from
> http://downloads.yoctoproject.org/releases/uninative/0.95/x86_64-nativesdk-libc.tar.bz2;sha256sum=26d46c61ad88cc245e31c88549717c0092a838d111b93ec169d88b08cc027581
>
>
> NOTE: Preparing RunQueue
> NOTE: Executing SetScene Tasks
> NOTE: Executing RunQueue Tasks
> ERROR: quilt-native-0.64-r0 do_populate_sysroot: Error executing a python
> function in exec_python_func() autogenerated:
>
> The stack trace of python calls that resulted in this exception/failure was:
> File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
>      0001:
>  *** 0002:relocatable_binaries_preprocess(d)
>      0003:
> File: '/opt/yocto/poky-krogoth-15.0.1/meta/classes/relocatable.bbclass',
> lineno: 6, function: relocatable_binaries_preprocess
>      0002:
>      0003:SYSROOT_PREPROCESS_FUNCS += "relocatable_binaries_preprocess"
>      0004:
>      0005:python relocatable_binaries_preprocess() {
>  *** 0006:    rpath_replace(d.expand('${SYSROOT_DESTDIR}'), d)
>      0007:}
> File: '/opt/yocto/poky-krogoth-15.0.1/meta/classes/chrpath.bbclass', lineno:
> 116, function: rpath_replace
>      0112:
>      0113:    for bindir in bindirs:
>      0114:        #bb.note ("Processing directory " + bindir)
>      0115:        directory = path + "/" + bindir
>  *** 0116:        process_dir (path, directory, d)
>      0117:
> File: '/opt/yocto/poky-krogoth-15.0.1/meta/classes/chrpath.bbclass', lineno:
> 105, function: process_dir
>      0101:                perms = None
>      0102:            else:
>      0103:                # Temporarily make the file writeable so we can
> chrpath it
>      0104:                os.chmod(fpath, perms|stat.S_IRWXU)
>  *** 0105:            process_file(cmd, fpath, rootdir, baseprefix, tmpdir,
> d)
>      0106:
>      0107:            if perms:
>      0108:                os.chmod(fpath, perms)
>      0109:
> File: '/opt/yocto/poky-krogoth-15.0.1/meta/classes/chrpath.bbclass', lineno:
> 7, function: process_file_linux
>      0003:
>      0004:def process_file_linux(cmd, fpath, rootdir, baseprefix, tmpdir,
> d):
>      0005:    import subprocess as sub
>      0006:
>  *** 0007:    p = sub.Popen([cmd, '-l',
> fpath],stdout=sub.PIPE,stderr=sub.PIPE)
>      0008:    err, out = p.communicate()
>      0009:    # If returned successfully, process stderr for results
>      0010:    if p.returncode != 0:
>      0011:        return
> File: '/usr/lib64/python2.7/subprocess.py', lineno: 710, function: __init__
>      0706:                                cwd, env, universal_newlines,
>      0707:                                startupinfo, creationflags, shell,
> to_close,
>      0708:                                p2cread, p2cwrite,
>      0709:                                c2pread, c2pwrite,
>  *** 0710:                                errread, errwrite)
>      0711:        except Exception:
>      0712:            # Preserve original exception in case os.close raises.
>      0713:            exc_type, exc_value, exc_trace = sys.exc_info()
>      0714:
> File: '/usr/lib64/python2.7/subprocess.py', lineno: 1327, function:
> _execute_child
>      1323:                except OSError as e:
>      1324:                    if e.errno != errno.ECHILD:
>      1325:                        raise
>      1326:                child_exception = pickle.loads(data)
>  *** 1327:                raise child_exception
>      1328:
>      1329:
>      1330:        def _handle_exitstatus(self, sts,
> _WIFSIGNALED=os.WIFSIGNALED,
>      1331:                _WTERMSIG=os.WTERMSIG, _WIFEXITED=os.WIFEXITED,
> Exception: OSError: [Errno 2] No such file or directory
>
> ERROR: quilt-native-0.64-r0 do_populate_sysroot: Function failed:
> relocatable_binaries_preprocess
> ERROR: Logfile of failure stored in:
> /opt/yocto/poky-krogoth-15.0.1/build/tmp/work/x86_64-linux/quilt-native/0.64-r0/temp/log.do_populate_sysroot.5686
> ERROR: Task 23
> (/opt/yocto/poky-krogoth-15.0.1/meta/recipes-devtools/quilt/quilt-native_0.64.bb,
> do_populate_sysroot) failed with exit code '1'
> NOTE: Tasks Summary: Attempted 12 tasks of which 0 didn't need to be rerun
> and 1 failed.
> Waiting for 0 running tasks to finish:
>
> Summary: 1 task failed:
>
> /opt/yocto/poky-krogoth-15.0.1/meta/recipes-devtools/quilt/quilt-native_0.64.bb,
> do_populate_sysroot
> Summary: There were 2 ERROR messages shown, returning a non-zero exit code.
> ----------------------------------------------------------------------------
>
> Thanks for your help.
>
> Luca
>
> Il 25/10/2016 22:27, Trevor Woerner ha scritto:
>
> In addition to the "bitbake core-image-minimal" command, what commands
> did you type before that (git clone, source <...>)? Did you edit any
>
>
> -----------------------------------------------------------
> Luca BOSCARIOL
> email: lboscariol at decelettronica.com
> -----------------------------------------------------------
> DEC ELETTRONICA S.r.l.
> Via dell'Artigianato 12/1 - 31040 Fossalta Maggiore di Chiarano (TV) Italy
> Tel: +39 0422 806097 - 806159 - Fax:+39 0422 806128 - URL:
> www.decelettronica.com - email: info at decelettronica.com
> -----------------------------------------------------------------------------------------
> Le informazioni contenute in questo messaggio di posta elettronica e/o nei
> file allegati sono da considerarsi strettamente riservate. Il loro utilizzo
> è consentito esclusivamente al destinatario del messaggio, per le finalità
> indicate nel messaggio stesso. Qualora riceveste questo messaggio senza
> esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via
> e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo
> dal Vostro sistema.
> Vi ricordiamo che costituisce comportamento contrario ai principi dettati
> dal Dlgs. 196/2003 il trattenere il messaggio stesso, divulgarlo, anche in
> parte, distribuirlo ad altri soggetti, copiarlo od utilizzarlo per finalità
> diverse.
> -----------------------------------------------------------------------------------------



More information about the yocto mailing list