您的位置:首页 > 大数据 > 人工智能

ubuntu下搭建rtems交叉编译环境所遇到的问题

2011-07-26 15:17 429 查看
error1:
第一遍编译binutils,一下是错误信息。
WARNING: `makeinfo' is missing on your system.  You should only need it if
        you modified a `.texi' or `.texinfo' file, or any other file
         indirectly affecting the aspect of the manual.  The spurious
         call might also be the consequence of using a buggy `make' (AIX,
         DU, IRIX).  You might want to install the `Texinfo' package or

         the `GNU make' package.  Grab either from any GNU archive site.
 
解决方法:
configure.ac里2405行:

     if ${MAKEINFO} --version "
       | egrep 'texinfo[^0-9]*(4\.([4-9] | [1-9]) | [5-9] | [1-9] [0-9])'
修改为egrep 'texinfo[^0-9]*(4\.([4-9] | [1-9]) | [5-9] | 4\.[1-9] [0-9])'
configure的6131行也有写错,但是不必修改;
 
原因
代码中的版本号匹配写法有误。
 
error2:
 
../../binutils-2.18/bfd/elf32-arm.c error :ignoring return value of 'asprintf', decleared with attribute warn_unused_result
 
解决方法:
 
在源代码中将asprintf的返回值赋值给一个变量
同类错误解决方法一致:
gas/read.c
gas/stabs.c
 
error3:
error : format not a string literal and no format arguments
 
../../binutiles-2.18/binutils/cxxfilt.c  error: format not a string literal and no format arguments
 
解决方法
将源码中的printf函数注释掉。或者将printf函数写成规范的printf("%s", str1);
as_bad()函数格式有误,解决方法类似,as_bad(_(%s), str2);
3454,3468,3586,3601,3706
 
 
error4:
tc_arm.c: error: 'firsttype' may be used uninitialized in this function
 
解决方法:
将其结构体成员变量defined初始化为0,index初始化为1; 
 
error5:
在环境变量修改之后,记得使用source启用环境变量
且环境变量要注意写正确。
 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息