在yocto建造码头 [英] Building docker on yocto

查看:437
本文介绍了在yocto建造码头的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

 错误:任务104(/ var / mshehery / release_7.3 / sheheryar / yocto / fido / meta / meta-virtualization / recipes-devtools / go / golang-cross_1.3.bb,do_compile)失败,退出代码'1'
我正在使用yocto的'fido'分支,元虚拟化和meta-openembedded。有人可以解释这个问题吗?



除了上述错误,我还收到了一些日志数据。我发布了可能会对问题进行深入分析的部分。



日志数据如下:

  | DEBUG:执行shell函数do_compile 
| GOARCH i586
| CC_FOR_TARGET gcc
| + set -e
| + [! -f run.bash]
| + uname
| + grep gold。* 2\.20
| + ld --version
| + [-d / selinux -a -f / selinux / booleans / allow_execstack -a -x / usr / sbin / selinuxenabled]
| + [-d / sys / fs / selinux -a -f / sys / fs / selinux / booleans / allow_execstack -a -x / usr / sbin / selinuxenabled]
| + uname -s
| + [Linux == GNU / kFreeBSD]
| ./make.bash:104:[:Linux:unexpected operator
| + rm -f ./pkg/runtime/runtime_defs.go
| + echo#Building C bootstrap工具。
| #构建C引导工具。
| + echo cmd / dist
| cmd / dist
| + cd ..
| + pwd
| + export GOROOT = / var / mshehery / Documents / git / fido / build / tmp / work / x86_64-poky-linux / golang-cross / 1.3-r0 / go
| + GOROOT_FINAL = / var / mshehery / Documents / git / fido / build / tmp / sysroots / x86_64-linux / usr / lib / i586-poky-linux / go
| + DEFGOROOT = -DGOROOT_FINAL =/ var / mshehery / Documents / git / fido / build / tmp / sysroots / x86_64-linux / usr / lib / i586-poky-linux / go
| + mflag =
| + uname
| + [Linux == Darwin]
| ./make.bash:124:[:Linux:unexpected operator
| + type -t gcc
| + type -t clang
| + [-z gcc -a -z -t:not found
| gcc是/ usr / bin / gcc -a -n -t:找不到
| clang:not found]
| + gcc -O2 -Wall -Werror -o cmd / dist / dist -Icmd / dist -DGOROOT_FINAL =/ var / mshehery / Documents / git / fido / build / tmp / sysroots / x86_64-linux / usr / lib / i586- po / linux / gocmd / dist / arm.c cmd / dist / buf.c cmd / dist / build.c cmd / dist / buildgc.c cmd / dist / buildgo.c cmd / dist / buildruntime.c cmd / dist / goc2c.c cmd / dist / main.c cmd / dist / plan9.c cmd / dist / unix.c cmd / dist / windows.c
| + ./cmd/dist/dist env -p
| go tool dist:unknown $ GOARCH i586
| + echo FAIL = true
| + eval FAIL = true
| + FAIL = true
| + [true = true]
| + exit 1
|警告:从shell命令退出代码1。
|错误:功能失败:do_compile(日志文件位于/var/mshehery/Documents/git/fido/build/tmp/work/x86_64-poky-linux/golang-cross/1.3-r0/temp/log.do_compile.31971 )


解决方案

当您 docker build



您可以运行失败前创建的最后一个图像,例如



--->使用缓存
---> a03f050edd2f
步骤4:ENTRYPOINT



在这种情况下



docker run -it a03f050edd2f bash



然后发出失败的命令,看看会发生什么



如果这不是秘密,请发布一个再现器,Dockerfile ..


I am getting the following error when trying to build docker on yocto

ERROR: Task 104 (/var/mshehery/Release_7.3/sheheryar/yocto/fido/meta/meta-virtualization/recipes-devtools/go/golang-cross_1.3.bb, do_compile) failed with exit code '1'

I am using the 'fido' branch of yocto, meta-virtualization and meta-openembedded. Can anyone elaborate the issue?

Apart from the above Error, I am also getting some Log Data. I am posting the portions which might give an insight into the problem

Log data follows:

| DEBUG: Executing shell function do_compile
| GOARCH i586
| CC_FOR_TARGET gcc
| + set -e
| + [ ! -f run.bash ]
| + uname
| + grep gold.* 2\.20
| + ld --version
| + [ -d /selinux -a -f /selinux/booleans/allow_execstack -a -x /usr/sbin/selinuxenabled ]
| + [ -d /sys/fs/selinux -a -f /sys/fs/selinux/booleans/allow_execstack -a -x /usr/sbin/selinuxenabled ]
| + uname -s
| + [ Linux == GNU/kFreeBSD ]
| ./make.bash: 104: [: Linux: unexpected operator
| + rm -f ./pkg/runtime/runtime_defs.go
| + echo # Building C bootstrap tool.
| # Building C bootstrap tool.
| + echo cmd/dist
| cmd/dist
| + cd ..
| + pwd
| + export GOROOT=/var/mshehery/Documents/git/fido/build/tmp/work/x86_64-poky-linux/golang-cross/1.3-r0/go
| + GOROOT_FINAL=/var/mshehery/Documents/git/fido/build/tmp/sysroots/x86_64-linux/usr/lib/i586-poky-linux/go
| + DEFGOROOT=-DGOROOT_FINAL="/var/mshehery/Documents/git/fido/build/tmp/sysroots/x86_64-linux/usr/lib/i586-poky-linux/go"
| + mflag=
| + uname
| + [ Linux == Darwin ]
| ./make.bash: 124: [: Linux: unexpected operator
| + type -t gcc
| + type -t clang
| + [ -z gcc  -a -z -t: not found
| gcc is /usr/bin/gcc -a -n -t: not found
| clang: not found ]
| + gcc -O2 -Wall -Werror -o cmd/dist/dist -Icmd/dist -DGOROOT_FINAL="/var/mshehery/Documents/git/fido/build/tmp/sysroots/x86_64-linux/usr/lib/i586-poky-linux/go" cmd/dist/arm.c cmd/dist/buf.c cmd/dist/build.c cmd/dist/buildgc.c cmd/dist/buildgo.c cmd/dist/buildruntime.c cmd/dist/goc2c.c cmd/dist/main.c cmd/dist/plan9.c cmd/dist/unix.c cmd/dist/windows.c
| + ./cmd/dist/dist env -p
| go tool dist: unknown $GOARCH i586
| + echo FAIL=true
| + eval FAIL=true
| + FAIL=true
| + [ true = true ]
| + exit 1
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /var/mshehery/Documents/git/fido/build/tmp/work/x86_64-poky-linux/golang-cross/1.3-r0/temp/log.do_compile.31971)

解决方案

When you docker buildyou get various layers.

You can run the last image created before the failure, example

---> Using cache ---> a03f050edd2f Step 4 : ENTRYPOINT

in that case

docker run -it a03f050edd2f bash

and then issue the command that fails, and see what happens

If this is not secret, post a reproducer, the Dockerfile..

这篇关于在yocto建造码头的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆