QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 2755|回复: 7

fedora13 编译skyeye-1-3-1出错,求助

[复制链接]
发表于 2010-8-16 16:16:24 | 显示全部楼层 |阅读模式
我的系统是fedora13,编译skyeye时无法通过,make lib能过,到了make步骤就出错了

gcc -DMODET -g -O2 -D_FILE_OFFSET_BITS=64 -DSTANDALONE -DDEFAULT_INLINE=0    -I. -I./common/include -I./common/ -Ithird-party/bfd/   -W -Wall -Wstrict-prototypes -Wmissing-prototypes  -g -O2 -MT uart_console.o -MD -MP -MF .deps/uart_console.Tpo -c -o uart_console.o `test -f 'utils/uart_console/uart_console.c' || echo './'`utils/uart_console/uart_console.c
utils/uart_console/uart_console.c:57: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:58: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:61: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:62: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:65: 警告:函数声明不是一个原型
utils/uart_console/uart_console.c: 在函数‘main’中:
utils/uart_console/uart_console.c:115: 警告:未使用的变量‘count’
utils/uart_console/uart_console.c: 在文件层:
utils/uart_console/uart_console.c:169: 警告:函数声明不是一个原型
make[2]: *** [uart_console.o] 错误 1

那位能给个提示是怎么回事啊
发表于 2010-8-16 20:45:10 | 显示全部楼层

fedora12编译没有问题

经过我们测试,fedora12编译没有问题,fedora12与fedora13差距应该不大,应该不会出现问题。这样,如果你方便找到一个fedora12的系统再测试下,如果还有同样的问题,我们再看看。还有不知你的skyeye-1-3-1的版本是否从官方网站下载,我给你个官方链接地址,你重新下载,再编译看一看,我们再讨论。

skyeye-1-3-1 url:   
http://sourceforge.net/projects/ ... rc1.tar.gz/download

[ 本帖最后由 tsinghuayuan86 于 2010-8-16 20:46 编辑 ]
回复

使用道具 举报

 楼主| 发表于 2010-8-17 10:57:07 | 显示全部楼层
1.3.1版本的我在fedora12的系统上编译通过了,不知道是不是fedora13的系统有什么地方不一样了。
1.3.0版本在fedora13的系统上编译报同样的错误
各位,该怎么办啊?
回复

使用道具 举报

 楼主| 发表于 2010-8-17 10:59:07 | 显示全部楼层
对了我的源码是从http://sourceforge.net上下载的
回复

使用道具 举报

发表于 2010-8-18 10:28:56 | 显示全部楼层
我也遇到来这种问题
回复

使用道具 举报

发表于 2010-8-19 11:00:09 | 显示全部楼层

回复 1# baiheng222 的帖子

昨天做实验遇到了同样的问题,解决了,下面是实验记录的一部分

出现这种问题的解决办法
utils/uart_console/uart_console.c:58: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:59: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:62: 错误:expected identifier or ‘(’ before numeric constant
utils/uart_console/uart_console.c:63: 错误:expected identifier or ‘(’ before numeric constant

错误:expected identifier or ‘(’ before numeric constant
是因为在其它头文件中已将POLLRDNORM那些定义,此处是已被define
解决方法,将58到63行注释
//const uint32_t POLLRDNORM = 0x040;
//const uint32_t POLLRDBAND = 0x080;
//const uint32_t POLLPRI = 0x002;
//const uint32_t POLLOUT = 0x004;
//const uint32_t POLLWRNORM = 0x100;
//const uint32_t POLLWRBAND = 0x200;

因为在/usr/include/bits/poll.h中已经define,第32到35行
/* These values are defined in XPG4.2.  */
# define POLLRDNORM     0x040           /* Normal data may be read.  */
# define POLLRDBAND     0x080           /* Priority data may be read.  */
# define POLLWRNORM     0x100           /* Writing now will not block.  */
# define POLLWRBAND     0x200           /* Priority data may be written.  */

PS:建议能不能取消注册一个小时内不能发帖的限制,本来昨天晚上应该把这个帖子回复的,后来等不及1个小时睡了,延迟大概10个小时,时间是很重要的
回复

使用道具 举报

发表于 2010-8-20 15:08:55 | 显示全部楼层

回复 6# guozan523 的帖子

感觉楼上这位同志
    按照楼上的修改方法可以解决问题,但通用与否还不能确定,因为有可能某些平台没有定义这些symbol。我在fedora12与fedora13中对比了一下,发现/usr/include/bits/poll.h这个文件基本相同,但不知为何,fedora12没有报错,而fedora13却出了问题。
    skyeye-1.3.1在fedora13上编译运行,大家可以按楼上的方法。我们已经把这个问题进行了修正,大概的方法就是对上述的4个symbol进行定义判断,然后再选择定义与否。在马上要推出的skyeye-1.3.2的版本中这个问题将不会出现。
   最后 感谢提问者,也感谢各位热心的同志的积极回答,skyeye将会因您们而更加完善!

[ 本帖最后由 tsinghuayuan86 于 2010-8-21 10:21 编辑 ]
回复

使用道具 举报

 楼主| 发表于 2010-8-23 16:19:16 | 显示全部楼层
谢谢各位的帮忙,小弟正在学习用skyeye移植uboot,以后少不了要麻烦大家。谢谢
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-3-28 21:36 , Processed in 0.087246 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表