ild_t4240qds/tmp/sysroots/x86_64-linux/usr/bin/automake line 3936.
| WARNING: exit code 255 from a shell command.
| ERROR: Function failed: do_configure (log file is located at /home/eric/QorIQ-SDK-V2.0-20160527-yocto/build_t4240qds/tmp/work/x86_64-linux/libtool-native/2.4.6-r0/temp/log.do_configure.2454)
原因是 Deepin的 perl版本较新,老的正则表达式格式不识别 ,
解决方法是:修改/home/eric/QorIQ-SDK-V2.0-20160527-yocto/build_t4240qds/tmp/sysroots/x86_64-linux/usr/bin/automake文件的:
sub substitute_ac_subst_variables
{
my ($text) = @_;
$text =~ s/\${([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge;
return $text;
}
改成:
sub substitute_ac_subst_variables { my ($text) = @_; # $text =~ s/\${([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge; $text =~ s/\$[{]([^ \t=:+{}]+)}/substitute_ac_subst_variables_worker ($1)/ge; return $text; }
之后,再次执行
-> bitbake -c cleansstate fsl-toolchain
-> bitbake fsl-toolchain
出现报错 :
tmplen = strftime (tmpbuf, tmpbufsize, locale_format, &tm); ^~~~~~
之类的。
这个错误的原因应该是Deepin系统的编译器版本与yocto要求的编译器版本差别太大导致的, Deepin的GCC版本试试7.6,而freescale 官方要求的经过验证的ubuntu14.04中的gcc版本才4.8,所以怀疑GCC版本过高捣的鬼。
于是降低gcc版本。
执行
-> sudo apt-get install gcc-4.8
-> sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 100
同样降低g++版本
-> sudo apt-get install g++-4.8
-> sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 100
重新执行
-> bitbake fsl-toolchain
又出现以下报错
| Can't locate find.pl in @INC (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.2 /usr/local/share/perl/5.26.2 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at perlpath.pl line 7.
| WARNING: exit code 2 from a shell command. | ERROR: Function failed: do_configure (log file is located at /home/eric/QorIQ-SDK-V2.0-20160527-yocto/build_t4240qds/tmp/work/x86_64-linux/openssl-native/1.0.2d-r0/temp/log.do_configure.65569) ERROR: Task 402 (virtual:native:/home/eric/QorIQ-SDK-V2.0-20160527-yocto/sources/poky/meta/recipes-connectivity/openssl/openssl_1.0.2d.bb, do_configure) failed with exit code '1'
估计又是perl版本搞的鬼,解决方法是拷贝一个find.pl过来
-> sudo cp /home/eric/QorIQ-SDK-V2.0-20160527-yocto/sources/poky/meta/recipes-connectivity/openssl/openssl/find.pl /etc/perl/
重新执行
-> bitbake fsl-toolchain
之后再无报错 ,直到 编译完成 。
完美解决!
最后再插一嘴,Deepin系统用着正不错,最最符合中国人的Linux版本了,受够了ubuntu上慢腾腾的 firefox, 开着 360安全浏览器,微信,流畅的,我已经仿佛忘了我是在用VMware+Linux了。
参考了以下文章:
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
https://www.cnblogs.com/zengjfgit/p/9178523.html
https://blog.csdn.net/bird_fly1024/article/details/81451662
http://www.cnblogs.com/zengjfgit/p/9178571.html
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
安装多个 perl :
htt