Chinaunix首页 | 论坛 | 博客
  • 博客访问: 237673
  • 博文数量: 21
  • 博客积分: 796
  • 博客等级: 军士长
  • 技术积分: 305
  • 用 户 组: 普通用户
  • 注册时间: 2011-07-16 01:03
文章分类
文章存档

2020年(1)

2017年(1)

2016年(1)

2015年(2)

2012年(9)

2011年(7)

我的朋友

分类: LINUX

2012-04-07 20:24:45

今天需要在ubuntu10.10系统中编译gdb-6.8,编译器为gcc-4.4.5。进入gdb-6.8源码目录后按照惯例执行:

        ./configure; make; make install
                
编译过程中得到下面错误信息:

        cc1: warnings being treated as errors
        linux-nat.c: In function ‘linux_nat_info_proc_cmd’:
        linux-nat.c:2879: error: ignoring return value of ‘fgets’, declared with attribute warn_unused_result

这里提示警告信息被作为错误处理,那应该是Makefile中gcc传递了-Werror选项。原本想打开Makefile改一下,但试了一下
        
        ./configure --hlep
        
发现有这样的选项

        --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
        --enable-werror         enable -Werror in bootstrap stage2 and later
        
于是,重新在gdb-6.8目录中执行

        ./configure --disable-werror
        make
        
后面的编译过程顺利完成,没有再出现错误。
阅读(11184) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

重返人生2012-04-10 02:06:47

错误信息