打印
[i.MX]

Imx6Q [fsl-yocto-3.10.17_1.0.0]上修改源码,编译的问题

[复制链接]
14978|19
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
TriggerHuang|  楼主 | 2014-10-30 10:54 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
Hi Dears,
目前在飞思卡尔官网发现已经support 3.10.17了,但是发现它的编译工具已经不是LTIB了,而是换成了
Yocto,按照文档《Freescale_Yocto_Project_User's_Guide.pdf》进行如下操作后,有些问题想请教一下。
$ repo init -u git://git.freescale.com/imx/fsl-arm-yocto-bsp.git -b imx-3.10.17-1.0.0_ga
$ repo sync
$ MACHINE=imx6qsabresd source fsl-setup-release.sh –b build-x11 -e x11
$ bitbake fsl-image-x11
我这边的硬件平台是Imx6Q,根据以往的经验,升级到3.10以后,我至少需要修改以下模块的代码来配合项目需求:
1, kernel
2,Uboot
3,Xorg 驱动
4,Gstreamer 插件。
但是我在运行“bitbake fsl-image-x11”后,并没有找到这些模块的代码,以前在LTIB中是有详细地说明,请问在Yocto下,有没有类似的说明呢? 另外当我找到这些代码,并做完修改以后,是全部单独编译呢,还是Yocto可以提供集中编译?
谢谢

相关帖子

沙发
FSL_TICS_Rita| | 2014-10-30 11:18 | 只看该作者
楼主你好,yocto的结构和ltib是不一样的。使用yocto编译的话,你按照文档才操作就OK的了。

使用特权

评论回复
板凳
TriggerHuang|  楼主 | 2014-10-30 11:23 | 只看该作者
多谢Rita的及时回复。
请问在Ycoto下,编译kernel, uboot、 xorg driver以及gstreamer plugin的详细文档是哪一份啊?
他们的code分别在fsl-release-bsp/build/ 下的哪个位置呢?

使用特权

评论回复
地板
TriggerHuang|  楼主 | 2014-10-30 14:49 | 只看该作者
FSL_TICS_Rita 发表于 2014-10-30 11:18
楼主你好,yocto的结构和ltib是不一样的。使用yocto编译的话,你按照文档才操作就OK的了。 ...


多谢Rita的及时回复。
请问在Ycoto下,编译kernel, uboot、 xorg driver以及gstreamer plugin的详细文档是哪一份啊?
他们的code分别在fsl-release-bsp/build/ 下的哪个位置呢?

使用特权

评论回复
5
FSL_TICS_Rita| | 2014-10-30 15:46 | 只看该作者
TriggerHuang 发表于 2014-10-30 11:23
多谢Rita的及时回复。
请问在Ycoto下,编译kernel, uboot、 xorg driver以及gstreamer plugin的详细文档是 ...

楼主你好,关于编译的话Freescale_Yocto_Project_User's_Guide.pdf 文档中有详细介绍。如果你哪里有问题再联系我。
关于你提到的编译以后的代码在哪里,Yocto 的结构和LTIB有很大的区别。以编译X11为例子的话,编译后的code你要到build-x11/tmp/work/imx6qsabresd-poky-linux-gnueabi/linux-imx/3.10.17-r0/git可以看到。

使用特权

评论回复
6
FSL_TICS_Rita| | 2014-11-3 16:11 | 只看该作者
楼主你好,请问你帖中问题是否已经解决了?如果没有,欢迎继续在这里讨论哈~~

使用特权

评论回复
7
TriggerHuang|  楼主 | 2014-11-5 11:52 | 只看该作者
FSL_TICS_Rita 发表于 2014-11-3 16:11
楼主你好,请问你帖中问题是否已经解决了?如果没有,欢迎继续在这里讨论哈~~ ...

谢谢。估计还是因为对Ycoto整个技术细节不了解。
因为以前做别的项目,一般都是通过git或svn直接把相关模块的最新代码下载下载(比如X driver),然后直接修改source code,编译、测试以及生成patch等。现在Ycoto的source下面的一些文件都不是源码,而是一些配置文件,不是很清楚他们的意义,也都不知道如何修改他们,也不知道他们和源代码的关系是什么。请问有这方面的介绍文档么?

使用特权

评论回复
8
FSL_TICS_Rita| | 2014-11-5 15:31 | 只看该作者
TriggerHuang 发表于 2014-11-5 11:56
另外,在Ubuntu12.04的Host机上,用bitbake编译imx6qsabresd时,还是会经常发生一些网络方面的错误,难道 ...

楼主你好,使用Yocto的话是要连网的,而ltib是不用的。你提到说会发生网络方面的错误,我也不确定是哪里的问题,请问你能将错误信息发给我吗,我看一下。

使用特权

评论回复
9
FSL_TICS_Rita| | 2014-11-5 15:34 | 只看该作者
TriggerHuang 发表于 2014-11-5 11:52
谢谢。估计还是因为对Ycoto整个技术细节不了解。
因为以前做别的项目,一般都是通过git或svn直接把相关模 ...

我们这边也是刚开始用Yocto,大家一起学习熟悉吧。Yocto的结构和LTIB有很大的区别,不过u-boot已经内核等的代码还是一样的,只是路径变了,编译命令变化了的。具体的文档介绍,目前还没有,有的话会第一时间分享给大家的。

使用特权

评论回复
10
TriggerHuang|  楼主 | 2014-11-10 10:21 | 只看该作者
FSL_TICS_Rita 发表于 2014-11-5 15:31
楼主你好,使用Yocto的话是要连网的,而ltib是不用的。你提到说会发生网络方面的错误,我也不确定是哪里 ...

搭建好YOCTO开发环境以后,通过如下动作来编译。
1,  通过repo命令,用-b imx-3.10.17-1.0.0_ga来进行下载。
2,  MACHINE=imx6qsabresd source fsl-setup-release.sh âb build-x11 -e x11
3,  bitbake fsl-image-x11
在编译了几个小时候,就出现了如下网络错误。这种错误一般怎么处理啊?我相信在国内,应该很多人碰到这种问题吧?

ERROR: Fetcher failure: Fetch command failed with exit code 4, output:
2014-11-08 20:36:11 (4.65 KB/s) - Data connection: Connection timed out; Control connection closed.
2014-11-08 20:40:45 (2.96 KB/s) - Data connection: Connection timed out; Control connection closed.

ERROR: Function failed: Fetcher failure for URL: 'ftp杠杠:xmlsoft.org/libxml2/libxml2-2.9.1.tar.gz;name=libtar'. Unable to fetch URL from any source.
ERROR: Logfile of failure stored in: /home/release-bsp/fsl-release-bsp/build/tmp/work/x86_64-linux/libxml2-native/2.9.1-r0/temp/log.do_fetch.3175
ERROR: Task 1135 (virtual:native:/home/release-bsp/fsl-release-bsp/sources/poky/meta/recipes-core/libxml/libxml2_2.9.1.bb, do_fetch) failed with exit code '1'
ERROR: Fetcher failure: Fetch command failed with exit code 4, output:
2014-11-08 20:26:35 (1.52 KB/s) - Data connection: Connection timed out; Data transfer aborted.
2014-11-08 20:28:09 (1.29 KB/s) - Data connection: Connection timed out; Control connection closed.

ERROR: Function failed: Fetcher failure for URL: 'ftp:杠杠ftp.gnu.org/gnu/gettext/gettext-0.18.3.1.tar.gz'. Unable to fetch URL from any source.
ERROR: Logfile of failure stored in: /home/release-bsp/fsl-release-bsp/build/tmp/work/x86_64-linux/gettext-native/0.18.3.1-r0/temp/log.do_fetch.2922
ERROR: Task 1096 (virtual:native:/home/release-bsp/fsl-release-bsp/sources/poky/meta/recipes-core/gettext/gettext_0.18.3.1.bb, do_fetch) failed with exit code '1'
WARNING: Failed to fetch URL ftp:杠杠ftp.gnu.org/gnu/gettext/gettext-0.18.3.1.tar.gz, attempting MIRRORS if available
ERROR: Fetcher failure: Fetch command failed with exit code 4, output:
2014-11-08 17:40:43 (4.26 KB/s) - Data connection: Connection timed out; Control connection closed.
2014-11-08 17:43:17 (3.45 KB/s) - Data connection: Connection timed out; Data transfer aborted.
ERROR: Function failed: Fetcher failure for URL: 'ftp:杠杠ftp.gnu.org/gnu/gcc/gcc-4.8.1/gcc-4.8.1.tar.bz2'. Unable to fetch URL from any source.
ERROR: Logfile of failure stored in: /home/release-bsp/fsl-release-bsp/build/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/gcc-cross-initial/4.8.1-r0/temp/log.do_fetch.26607
ERROR: Task 795 (/home/release-bsp/fsl-release-bsp/sources/poky/meta/recipes-devtools/gcc/gcc-cross-initial_4.8.bb, do_fetch) failed with exit code '1'
ERROR: Fetcher failure: Fetch command failed with exit code 4, no outputERROR: Function failed: Fetcher failure for URL: 'ftp:杠杠ftp.gnu.org/gnu/gettext/gettext-0.18.3.1.tar.gz'. Unable to fetch URL from any source.ERROR: Logfile of failure stored in: /home/release-bsp/fsl-release-bsp/build/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/gettext/0.18.3.1-r0/temp/log.do_fetch.3198ERROR: Task 1323 (/home/release-bsp/fsl-release-bsp/sources/poky/meta/recipes-core/gettext/gettext_0.18.3.1.bb, do_fetch) failed with exit code '1'

使用特权

评论回复
11
TriggerHuang|  楼主 | 2014-11-10 10:31 | 只看该作者
FSL_TICS_Rita 发表于 2014-11-5 15:34
我们这边也是刚开始用Yocto,大家一起学习熟悉吧。Yocto的结构和LTIB有很大的区别,不过u-boot已经内核等 ...

Hi Rita, 正好有一个yocto的命令想请教您。 如何单独处理一个模块呢? 比如,gst-fsl-plugin。
假设我已经成功运行过bitbake fsl-image-multimedia-full了。
1,如何重新生成带有FreeScale patch的完整的gst-fsl-plugin 的code呢?我记得以前LTIB是 ./ltib -m prep -p gst-fsl-plugin.
2,在基于1步骤后,对代码进行修改完以后,如何单独编译gst-fsl-plugin呢? 我用bitbake -b gst-fsl-plugin,还是回编译很多模块,需要很长时间。难道我每改一次code,就得编译N久???
3,如果对gst-fsl-plugin模块进行make clean动作呢?
4,当我编译、验证好自己添加的功能后,请问如何将之添加到sources/meta-fsl-arm/recipes-multimedia/gstreamer目录下,以及需要许改哪些配置文件。这样,下次我再运行bitbake fsl-image-multimedia-full就能将我的修改直接编译进去,否则我还得重新生成code,重新把修改移植,又重新编译。

使用特权

评论回复
12
TriggerHuang|  楼主 | 2014-11-26 15:10 | 只看该作者
感谢Rita的详细解答,但是“结帖给分”中老是弹出“分数错误”,没办法,我只能“无满意答案结帖”。

使用特权

评论回复
13
金易龙| | 2014-11-27 01:20 | 只看该作者
Hi Rita, 正好有一个yocto的命令想请教您。 如何单独处理一个模块呢? 比如,gst-fsl-plugin。
假设我已经成功运行过bitbake fsl-image-multimedia-full了。
1,如何重新生成带有FreeScale patch的完整的gst-fsl-plugin 的code呢?我记得以前LTIB是 ./ltib -m prep -p gst-fsl-plugin.
2,在基于1步骤后,对代码进行修改完以后,如何单独编译gst-fsl-plugin呢? 我用bitbake -b gst-fsl-plugin,还是回编译很多模块,需要很长时间。难道我每改一次code,就得编译N久???
3,如果对gst-fsl-plugin模块进行make clean动作呢?
4,当我编译、验证好自己添加的功能后,请问如何将之添加到sources/meta-fsl-arm/recipes-multimedia/gstreamer目录下,以及需要许改哪些配置文件。这样,下次我再运行bitbake fsl-image-multimedia-full就能将我的修改直接编译进去,否则我还得重新生成code,重新把修改移植,又重新编译。


以上问题我也有相同的疑问。

使用特权

评论回复
14
mini1986| | 2015-4-4 11:07 | 只看该作者
还搞着老版本的Linux 3.0.35 BSP......

使用特权

评论回复
15
nihaojhjhh| | 2015-9-17 08:57 | 只看该作者
你好。我是刚入手yocto,是基于imx6q 构建嵌入式linux,请问 你那有什么资料吗?现在我真的急需。谢谢。

使用特权

评论回复
16
nihaojhjhh| | 2015-9-17 08:58 | 只看该作者
你好。我是刚入手yocto,是基于imx6q 构建嵌入式linux,请问 你那有什么资料吗?现在我真的急需。谢谢。qq 414024217

使用特权

评论回复
17
healySun| | 2015-9-19 11:55 | 只看该作者
我也遇到问题

1. $ cd fsl-release-bsp

2. $ source setup-environment

3. $ MACHINE=imx6qsabresd source fsl-setup-release.sh -b build-x11 -e x11

4. $ bitbake fsl-image-gui



snapshot of error



NOTE: Preparing runqueue
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
ERROR: Function failed: do_compile (log file is located at /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/temp/log.do_compile.7500)
ERROR: Logfile of failure stored in: /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/temp/log.do_compile.7500
Log data follows:
| DEBUG: SITE files ['endian-little', 'bit-32', 'arm-common', 'common-linux', 'common-glibc', 'arm-linux', 'arm-linux-gnueabi', 'common']
| DEBUG: Executing shell function do_compile
| NOTE: make -j 2
| /bin/bash /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/git/git_version.sh -k -s /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/git -o git_version.h
| fatal: ref HEAD is not a symbolic ref
| git_version.sh: Output is unchanged, keeping git_version.h
| make  all-recursive
| make[1]: Entering directory `/home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/build'
| Making all in .
| make[2]: Entering directory `/home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/build'
| arm-poky-linux-gnueabi-g++  -march=armv7-a -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a9 --sysroot=/home/healy/fsl-release-bsp/build-x11/tmp/sysroots/imx6qsabresd -Wall -Werror   -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -fstack-protector-all -D_FORTIFY_SOURCE=2   -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o stap stap-main.o stap-session.o stap-parse.o stap-staptree.o stap-elaborate.o stap-translate.o stap-tapsets.o stap-buildrun.o stap-loc2c.o stap-hash.o stap-mdfour.o stap-cache.o stap-util.o stap-coveragedb.o stap-dwarf_wrappers.o stap-tapset-been.o stap-tapset-procfs.o stap-tapset-timers.o stap-tapset-netfilter.o stap-tapset-perfmon.o stap-tapset-mark.o stap-tapset-itrace.o stap-tapset-utrace.o stap-task_finder.o stap-dwflpp.o stap-rpm_finder.o stap-setupdwfl.o stap-remote.o stap-privilege.o stap-cmdline.o stap-tapset-dynprobe.o stap-tapset-method.o stap-translator-output.o stap-stapregex.o stap-stapregex-tree.o stap-stapregex-parse.o stap-stapregex-dfa.o  -Wl,--start-group -ldw -lebl -Wl,--end-group -lelf -lsqlite3 -lpthread
| The script example index is outdated, run
|     cd /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/git/testsuite/systemtap.examples && \
|     perl examples-index-gen.pl
| to regenerate it.
| stap-translate.o: file not recognized: File truncated
| collect2: error: ld returned 1 exit status
| make[2]: *** [stap] Error 1
| make[2]: Leaving directory `/home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/build'
| make[1]: *** [all-recursive] Error 1
| make[1]: Leaving directory `/home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/build'
| make: *** [all] Error 2
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Function failed: do_compile (log file is located at /home/healy/fsl-release-bsp/build-x11/tmp/work/cortexa9hf-vfp-neon-poky-linux-gnueabi/systemtap/2.5+gitAUTOINC+8f0fcd995f-r0/temp/log.do_compile.7500)
ERROR: Task 3120 (/home/healy/fsl-release-bsp/sources/poky/meta/recipes-kernel/systemtap/systemtap_git.bb, do_compile) failed with exit code '1'

Second Keyboard Interrupt, stopping...

Summary: 1 task failed:
  /home/healy/fsl-release-bsp/sources/poky/meta/recipes-kernel/systemtap/systemtap_git.bb, do_compile
Summary: There was 1 ERROR message shown, returning a non-zero exit code.
NOTE: Sending SIGTERM to remaining 1 tasks

那位能帮我看看,

使用特权

评论回复
18
mini1986| | 2015-9-21 11:17 | 只看该作者
healySun 发表于 2015-9-19 11:55
我也遇到问题

1. $ cd fsl-release-bsp

你换个新版本试试呢,好像在3.14.28上没有遇到这样的问题......

使用特权

评论回复
19
xuanxuan170| | 2015-10-14 16:50 | 只看该作者
受教了   ,目前一直在用LTIB编译呢。
从你们讨论看来yocto编译IMX6,有点略坑啊

使用特权

评论回复
20
zlx-2014| | 2015-11-12 09:56 | 只看该作者
  刚刚开始使用yocto 编译 imx6u,整两天了 还没编出个结果来

使用特权

评论回复
发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

4

主题

49

帖子

1

粉丝